diff options
author | bors[bot] <26634292+bors[bot]@users.noreply.github.com> | 2021-03-02 00:01:14 +0000 |
---|---|---|
committer | GitHub <[email protected]> | 2021-03-02 00:01:14 +0000 |
commit | 477c1ac105a3b2ed8aafc8c3b09da81984725461 (patch) | |
tree | b6fc2472e099bcd7237b2d6f8d79b1484112d7c4 /crates/cfg/Cargo.toml | |
parent | 10a57b8109cbc54c6f6aaae3b61a56fd0529a24a (diff) | |
parent | a157f19bf5bcfe6d59a754a0cb28ece30c526848 (diff) |
Merge #7827
7827: Fix proc macro TokenStream::from_str token ids r=vlad20012 a=vlad20012
To be honest, I don't know what it changes from a user perspective.
Internally, this fixes spans (token ids) of a `TokenStream` parsed from a string:
```rust
#[proc_macro_derive(FooDerive)]
pub fn foo_derive(item: TokenStream) -> TokenStream {
"fn foo() {}".parse().unwrap()
}
```
Previously, `TokenStream` was constructed from tokens with incremental ids (that conflicted with call-site tokens). Now they are `-1`.
Co-authored-by: vlad20012 <[email protected]>
Diffstat (limited to 'crates/cfg/Cargo.toml')
0 files changed, 0 insertions, 0 deletions