Skip to content

proc macro API: Making enum Delimiter non-exhaustive  #54248

Closed
@petrochenkov

Description

@petrochenkov

... with an eye on extending it with angle brackets < TOKEN_TREES > in the future.

Yes, </> may be unbalanced, but I suspect that we can always consider balanced angle brackets as a group with minimal breakage (based on estimates from #53578).

Lang team is seriously intending to remove turbofish from value paths (value::<Type> => value<Type>) despite all the grammar implications, and angle-bracketed groups may be the only way to do it without requiring backtracing from parsers.

Is it realistic to make this change now, when 1.29 with stabilized proc macro API was just released?
This stabilization was never announced in release notes or 1.29 blog post, so it may be possible that only infrastructural crates like proc-macro2/syn/... are affected.
What are the alternatives if we want to make < ... > a group?
cc @dtolnay @alexcrichton @varkor

Metadata

Metadata

Assignees

No one assigned

    Labels

    T-libs-apiRelevant to the library API team, which will review and decide on the PR/issue.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions