pub enum Arg {
TypeName(TypeName),
Name(String),
StringLit(String),
Literal(String),
Code(CodeBlock),
}Expand description
An argument to a CodeBlock format string.
Variants§
TypeName(TypeName)
A type name reference (used by %T).
Name(String)
A name string (used by %N).
StringLit(String)
A string literal value (used by %S).
Literal(String)
A literal string value or nested code block (used by %L).
Code(CodeBlock)
A nested code block (used by %L).
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Arg
impl<'de> Deserialize<'de> for Arg
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl From<StringLitArg> for Arg
impl From<StringLitArg> for Arg
Source§fn from(s: StringLitArg) -> Self
fn from(s: StringLitArg) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for Arg
impl RefUnwindSafe for Arg
impl Send for Arg
impl Sync for Arg
impl Unpin for Arg
impl UnsafeUnpin for Arg
impl UnwindSafe for Arg
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more