Skip to main content

punct

Macro punct 

Source
macro_rules! punct {
    ($tt:tt) => { ... };
}
Expand description

Punct quasi-quoting macro.

§Examples

use met::punct;

let punct = punct! { < };

assert!(punct.is_char('<'));
assert!(punct.is_alone());

If the token isn’t a punct, the macro will panic.

use met::punct;

punct! { variable };