Skip to content
This repository was archived by the owner on Dec 27, 2022. It is now read-only.

Expression macro cannot be used as enum discriminant #11

Closed
dtolnay opened this issue Mar 8, 2017 · 2 comments
Closed

Expression macro cannot be used as enum discriminant #11

dtolnay opened this issue Mar 8, 2017 · 2 comments
Labels

Comments

@dtolnay
Copy link
Owner

dtolnay commented Mar 8, 2017

#[macro_use]
extern crate demo_hack;

pub enum E {
    A = add_one!(1)
}

rust-lang/rust#40350

@dtolnay dtolnay added the bug label Mar 8, 2017
@Mark-Simulacrum
Copy link

This has been fixed in Rust master, just so you know; I don't know if any changes here need to be made.

@dtolnay
Copy link
Owner Author

dtolnay commented May 29, 2017

Thank you! I will close the issue when I confirm it is fixed in a nightly.

@dtolnay dtolnay closed this as completed Oct 23, 2017
# for free to subscribe to this conversation on GitHub. Already have an account? #.
Labels
Projects
None yet
Development

No branches or pull requests

2 participants