-
Couldn't load subscription status.
- Fork 141
{instruction,program}error!: remove unused std features #256
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
{instruction,program}error!: remove unused std features #256
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Very nice, thanks!
| use solana_frozen_abi_macro::{AbiEnumVisitor, AbiExample}; | ||
| #[cfg(feature = "std")] | ||
| #[cfg(feature = "frozen-abi")] | ||
| extern crate std; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
will this be confusing since std is included even without a std feature?
i guess my expectation for a no-std crate is that it doesn't use std unless you pass std feature.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
frozen-abi doesn't count imo, if someone pulls that in they have other problems
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd agree with that -- the frozen-abi feature is only used for a specific test build, and the macros happen to require std, so we have to pull in std somehow.
* remove unused std features * fmt * add extern crate std under frozen-abi
The instruction-error and program-error crates have
stdfeatures in Cargo.toml that don't do anything