Enum clippy_utils::macros::FormatParamKind
source · Expand description
How a format parameter is used in the format string
Variants§
Implicit
An implicit parameter , such as {}
or {:?}
.
Numbered
A parameter with an explicit number, e.g. {1}
, {0:?}
, or {:.0$}
Starred
A parameter with an asterisk precision. e.g. {:.*}
.
Named(Symbol)
A named parameter with a named value_arg
, such as the x
in format!("{x}", x = 1)
.
NamedInline(Symbol)
An implicit named parameter, such as the y
in format!("{y}")
.
Trait Implementations§
source§impl Clone for FormatParamKind
impl Clone for FormatParamKind
source§fn clone(&self) -> FormatParamKind
fn clone(&self) -> FormatParamKind
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for FormatParamKind
impl Debug for FormatParamKind
source§impl PartialEq<FormatParamKind> for FormatParamKind
impl PartialEq<FormatParamKind> for FormatParamKind
source§fn eq(&self, other: &FormatParamKind) -> bool
fn eq(&self, other: &FormatParamKind) -> bool
impl Copy for FormatParamKind
impl Eq for FormatParamKind
impl StructuralEq for FormatParamKind
impl StructuralPartialEq for FormatParamKind
Auto Trait Implementations§
impl RefUnwindSafe for FormatParamKind
impl Send for FormatParamKind
impl Sync for FormatParamKind
impl Unpin for FormatParamKind
impl UnwindSafe for FormatParamKind
Blanket Implementations§
Layout§
Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain repr(...)
attributes. Please see the Rust Reference’s “Type Layout” chapter for details on type layout guarantees.
Size: 8 bytes
Size for each variant:
Implicit
: 0 bytesNumbered
: 0 bytesStarred
: 0 bytesNamed
: 4 bytesNamedInline
: 4 bytes