Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Migrate neli-proc-macros to syn 2.0.x #241

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

duMagnus
Copy link

@duMagnus duMagnus commented Jul 1, 2024

The transition to syn 2.x involved addressing several breaking changes from syn 1.x. Some of these changes were straightforward, such as the replacement of Tokens Add with Plus, Colon2 with PathSep, and the renaming of LifeTimeDef struct to LifeTimeParam. However, some changes required modifications to our structures. For instance, we now retrieve .meta from an Attribute instead of using .parse_meta(). Additionally, Paths now support .is_ident(), which simplifies their comparison.

The removal of NestedMeta necessitated a new approach to parsing nested elements from Paths using TokenTree tokens. These tokens can be Groups, Idents, Puncts, or Literals, enabling us to determine their purpose.

The transition to syn 2.x involved addressing several breaking changes
from syn 1.x. Some of these changes were straightforward, such as the
replacement of Tokens Add with Plus, Colon2 with PathSep, and the
renaming of LifeTimeDef struct to LifeTimeParam. However, some changes
required modifications to our structures. For instance, we now retrieve
.meta from an Attribute instead of using .parse_meta(). Additionally,
Paths now support .is_ident(), which simplifies their comparison.

The removal of NestedMeta necessitated a new approach to parsing nested
elements from Paths using TokenTree tokens. These tokens can be Groups,
Idents, Puncts, or Literals, enabling us to determine their purpose.
@duMagnus
Copy link
Author

Hello, next week works well for me if there are any tweaks needed on this code. Just please let me know if anything comes up!

@jbaublitz
Copy link
Owner

Hi @duMagnus, I'm currently reviewing this PR and will have a few comments to post a little bit later today.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants