Skip to content

Semicolons are not required on some statements in macros #34543

Closed
@jseyfried

Description

@jseyfried

For example, this compiles:

macro_rules! m { () => {
    let x = 1
    let y = 2
    println!("{}", x)
    println!("{}", y)
} }

fn main() {
    m!();
}

Metadata

Metadata

Assignees

Labels

P-highHigh priorityT-compilerRelevant to the compiler 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