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

Rustfmt adds extra semicolon after type_macro invocation #2294

Closed
Marwes opened this issue Dec 19, 2017 · 2 comments
Closed

Rustfmt adds extra semicolon after type_macro invocation #2294

Marwes opened this issue Dec 19, 2017 · 2 comments
Labels
a-macros bug Panic, non-idempotency, invalid code, etc.

Comments

@Marwes
Copy link
Contributor

Marwes commented Dec 19, 2017

Before

macro_rules! test {
    ($($t: expr)*) => { i32 }
}

type Test = test!{
    123
};

After

macro_rules! test {
    ($($t: expr)*) => { i32 }
}

type Test = test!{
                123
            };;

This unfortunately breaks the code since ;; is invalid.

@topecongiro
Copy link
Contributor

This is similar to #2290. Once rust-lang/rust#46835 gets merged this will be fixed by rustup update nightly && cargo install --force rustfmt-nightly.

@topecongiro topecongiro added bug Panic, non-idempotency, invalid code, etc. a-macros labels Dec 20, 2017
@topecongiro
Copy link
Contributor

Closed via rust-lang/rust#46835 and #2297.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
a-macros bug Panic, non-idempotency, invalid code, etc.
Projects
None yet
Development

No branches or pull requests

2 participants