Crate fmt_macros[−][src]
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
Macro support for format strings
These structures are used when parsing format strings for the compiler.
Parsing does not happen at runtime: structures of std::fmt::rt
are
generated instead.
Re-exports
extern crate std; |
use std::prelude::v1::*; |
pub use self::Piece::*; |
pub use self::Position::*; |
pub use self::Alignment::*; |
pub use self::Flag::*; |
pub use self::Count::*; |
use std::str; |
use std::string; |
use std::iter; |
Structs
Argument |
[ Experimental ] Representation of an argument specification. |
FormatSpec |
[ Experimental ] Specification for the formatting of an argument in the format string. |
ParseError |
[ Experimental ]
|
Parser |
[ Experimental ] The parser structure for interpreting the input format string. This is
modeled as an iterator over |
Enums
Alignment |
[ Experimental ] Enum of alignments which are supported. |
Count |
[ Experimental ] A count is used for the precision and width parameters of an integer, and can reference either an argument or a literal integer. |
Flag |
[ Experimental ] Various flags which can be applied to format strings. The meaning of these flags is defined by the formatters themselves. |
Piece |
[ Experimental ] A piece is a portion of the format string which represents the next part
to emit. These are emitted as a stream by the |
Position |
[ Experimental ] Enum describing where an argument for a format can be located. |