Skip to content

Use the bitflags! macro to implement FlagV1 #24974

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

Closed
wants to merge 1 commit into from

Conversation

tamird
Copy link
Contributor

@tamird tamird commented Apr 30, 2015

Closes #15738.

r? @alexcrichton this is another go at #24697. It turns out that rustc_bitflags doesn't need libcore, so this works by putting rustc_bitflags at the start of the chain in place of libcore. What do you think?

@tamird tamird force-pushed the fmt-bitflags branch 3 times, most recently from 6bf023b to 1d2a7e9 Compare April 30, 2015 05:36
@alexcrichton
Copy link
Member

Morally I feel like something has gone quite astray if libcore depends on something, and I don't think there's really much benefit to using the bitflags macro to generate a implementation. We'd also be highly unlikely to stabilize a bitflags-generated interface for the flags, so either way I'd personally hold off on trying to stabilize these flags until later.

@alexcrichton
Copy link
Member

For now I'm going to close this due to the need to probably take a more comprehensive look at this API in terms of what and how the flags are exposed, and that I think we should keep the bitflags API private for now as it's somewhat of an awkward way to expose an API surface. Thanks for the PR regardless, however!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Formatter::flags/std::fmt::rt::Flag should be implemented using the bitflags! macro
2 participants