Crate enso_macro_utils[−][src]
Expand description
A number of helper functions meant to be used in the procedural enso-shapely-macros definitions.
Structs
TypeGatherer | Visitor that accumulates all visited |
Functions
field_ident_token | Returns token that refers to the field. |
field_names | Returns names of the named fields. |
fields_list | Collects all fields, named or not. |
gather_all_type_reprs | All text representations of |
gather_all_types | All |
identifier_sequence | For given length returns sequence of identifiers like |
index_sequence | For given length, returns a sequence of Literals like |
last_type_arg | Last type argument of the last segment on the type path. |
map_tokens | Maps all the tokens in the stream using a given function. |
matching_ident | Is the given token an identifier matching to a given string? |
new_where_clause | Creates a new where clause from provided sequence of where predicates. |
path_matching_ident | Checks if a given |
path_segment_generic_args | Obtain list of generic arguments on the path’s segment. |
repr | Obtains text representation of given |
rewrite_stream | Rewrites stream replacing each token with a sequence of tokens returned by the given function. The groups (e.g. token tree within braces) are unpacked, rewritten and repacked into groups – the function is applied recursively. |
ty_path_generic_args | Obtain list of generic arguments on the path’s last segment. |
ty_path_type_args | Obtain list of type arguments on the path’s last segment. |
type_depends_on | Does type depends on the given type parameter. |
type_matches | Naive type equality test by comparing their text representations. |
type_matches_repr | Naive type equality test by comparing its representation with a string. |
variant_depends_on | Does enum variant depend on the given type parameter. |
Trait aliases
Str |