Releases: dtolnay/syn
Releases · dtolnay/syn
0.9.2
- Add
syn::parse_token_trees
to parse tokens from a string. Token trees are much simpler than an AST. This makes them easier to work with when they are sufficient for the task at hand, such as for example expanding a function-like macro. (#52, thanks @SimonSapin)
0.9.1
0.9.0
- Enum discriminant values and array lengths now support expressions instead of just usize literals (#31).
- Update
quote
dependency to 0.3. Make sure to check those release notes for an important update affecting repetitions. - Lots of progress on parsing Rust syntax beyond structs and enums (#4).
0.8.7
- Add
Generics::split_for_impl
which simplifies the handling of complex generic type signatures in a trait impl.
let (impl_generics, ty_generics, where_clause) = generics.split_for_impl();
quote! {
impl #impl_generics MyTrait for #name #ty_generics #where_clause {
// ...
}
}
0.8.6
0.8.5
0.8.4
0.8.3
0.8.2
- Fix a literal "///" appearing at the beginning of generated docstrings: rust-lang/rust#35900 (comment).
0.8.1
- Workaround for a compiler bug when building in release mode with rustc 1.12.0. Versions before and after 1.12.0 were not affected. rust-lang/rust#36875