Expand description
Token generation helpers for building TokenStreams without external dependencies.
Functions§
- arrow
- Emits
->(return type arrow). - braces
- Creates brace group: {tokens}
- brackets
- Creates bracket group: [tokens]
- compile_
error - Creates a compile_error!(“message”) invocation.
- extend
- Convenience: extends a Vec with an iterator.
- fat_
arrow - Emits
=>(match arm arrow). - generics
- Emits
<and>around tokens for generics. - group
- Creates a group (delimited tokens).
- ident
- Creates an identifier token.
- ident_
raw - Creates an identifier token, handling raw identifiers (r#keyword).
- literal_
str - Creates a string literal token.
- literal_
usize - Creates an integer literal token.
- parens
- Creates parentheses group: (tokens)
- path
- Emits a path like
::reifydb_type::FromFrame. Pass an empty first segment for a global path (::foo::bar). - path_
sep - Emits
::(path separator). - punct
- Creates a punctuation token with Alone spacing.
- punct_
joint - Creates a punctuation token with Joint spacing (for multi-char punctuation like ::).
- underscore
- Creates an underscore token for type inference placeholders. This is needed because Ident::new(“_”) panics in proc_macro v1.