rust/src/test/ui/ast-json
Nicholas Nethercote c290293cf2 Derive Rustc{En,De}codable for TokenStream.
`TokenStream` used to be a complex type, but it is now just a newtype
around a `Lrc<Vec<TreeAndJoint>>`. Currently it uses custom encoding
that discards the `IsJoint` and custom decoding that adds `NonJoint`
back in for every token tree. This requires building intermediate
`Vec<TokenTree>`s.

This commit makes `TokenStream` derive `Rustc{En,De}codable`. This
simplifies the code, and avoids the creation of the intermediate
vectors, saving up to 3% on various benchmarks. It also changes the AST
JSON output in one test.
2019-10-21 06:54:41 +11:00
..
ast-json-ice.rs Add default serialization for Idents 2019-08-27 23:02:22 +01:00
ast-json-output.rs Add default serialization for Idents 2019-08-27 23:02:22 +01:00
ast-json-output.stdout Derive Rustc{En,De}codable for TokenStream. 2019-10-21 06:54:41 +11:00