Macro kvarn::prelude::utils::ident_str

source ·
macro_rules! ident_str {
    ($item:ident $(, $($name:ident)+, $($generics:tt)+)?) => { ... };
}
Expand description

Return stringified representation of $item. This uses similar techniques to ident_str!.

§Examples

See fmt_field!.

If you have a generic struct:

use kvarn_utils::ident_str;

struct Foo<T: Eq + Clone> {
    bar: T,
}
assert_eq!(ident_str!(Foo, T, T: Eq + Clone), "Foo");