Crate workspacer_syntax

Source

Structs§

EnumSignatureGenerator
FnSignatureGenerator
MacroCallSignatureGenerator
MacroRulesSignatureGenerator
SignatureOptions
Control how we generate a signature string.
SignatureOptionsBuilder
Builder for SignatureOptions.
StructSignatureGenerator
TraitSignatureGenerator
TypeAliasSignatureGenerator

Enums§

SignatureOptionsBuilderError
Error type for SignatureOptionsBuilder

Traits§

GenerateSignature
A trait to generate a textual “signature” (or declaration line(s)) for different AST nodes (Fn, Struct, Enum, etc.), possibly with doc lines, etc.
MaybeHasSyntaxKind
RehydrateFromSignature

Functions§

clean_where_clause
Removes trailing commas from a where clause flattened to one line. If it’s just “where”, remove it entirely.
extract_docs
Extract doc lines from /// or /** ... */. We do NOT gather #[doc="..."] attributes here. Those can be handled separately if you want to unify them.
flatten_whitespace
Splits on all whitespace and rejoins with one space, trimming.
full_clean_where_clause
is_node_public
Check if a node is “public,” e.g. pub fn, pub struct, or #[macro_export].
post_process_spacing
Minimal post-processing to ensure correct spacing around arrows, where clauses, etc.
remove_comments_in_where_clause
New helper that blasts all //... line comments and /*...*/ block comments from the given where-clause text.