Skip to content

disallow | from the follow-set of pat2021 #84138

Closed
@nikomatsakis

Description

@nikomatsakis

In Edition 2021, the following should error:

macro_rules! foo {
    ($x:pat | $y:pat) => { }
}

fn main() { }

for the same reason that the following already errors:

macro_rules! foo {
    ($x:expr | $y:expr) => { }
}

fn main() { }

cc @rust-lang/project-edition-2021

Metadata

Metadata

Assignees

Labels

T-langRelevant to the language team

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions