[−][src]Crate syn_mid
Providing the features between "full" and "derive" of syn.
This crate provides the following two unique data structures.
-
syn_mid::ItemFn
-- A function whose body is not parsed.fn process(n: usize) -> Result<()> { ... } ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ ^ ^
-
syn_mid::Block
-- A block whose body is not parsed.{ ... } ^ ^
Other data structures are the same as data structures of syn. These are defined in this crate because they cannot be used in syn without "full" feature.
Optional features
syn-mid in the default features aims to provide the features between "full" and "derive" of syn.
clone-impls
— Clone impls for all syntax tree types.
Structs
Block | A braced block containing Rust statements. |
FieldPat | A single field in a struct pattern. |
ItemFn | A free-standing function: |
PatIdent | A pattern that binds a new variable: |
PatPath | A path pattern like |
PatReference | A reference pattern: |
PatStruct | A struct or struct variant pattern: |
PatTuple | A tuple pattern: |
PatTupleStruct | A tuple struct or tuple variant pattern: |
PatType | A type ascription pattern: |
PatWild | A pattern that matches any value: |
Receiver | The |
Signature | A function signature in a trait or implementation: |
Enums
FnArg | An argument in a function signature: the |
Pat | A pattern in a local binding, function signature, match expression, or various other places. |