dtolnay / proc-macro-workshop

Learn to write Rust procedural macros  [Rust Latam conference, Montevideo Uruguay, March 2019]
Apache License 2.0
4.13k stars 1.04k forks source link

Update projects and tests to 2021 edition #44

Closed dtolnay closed 2 years ago

dtolnay commented 2 years ago

At least the seq! project will require some rework because ident concatenation Variant#N is no longer legal syntax lexically. There may be other incompatibilities in the other projects as well.

dtolnay commented 2 years ago
error: prefix `Variant` is unknown
 --> tests/07-inclusive-range.rs:9:13
  |
9 |             Variant#N,
  |             ^^^^^^^ unknown prefix
  |
  = note: prefixed identifiers and literals are reserved since Rust 2021
help: consider inserting whitespace here
  |
9 -             Variant#N,
9 +             Variant #N,
  |