-
Couldn't load subscription status.
- Fork 119
Description
The recommendation for C-FEATURE says:-
Do not call the feature
use-stdorwith-stdor any creative name that is notstd.
I like this naming convention. Unfortunately, it's not always possible to follow. For example, say I want to add optional support for serde, the obvious name for such a feature would be serde. However, if some of my types can be derived automatically, I would also want to optionally depend on serde_derive. Part of my manifest will then end up as follows:
[features]
serde = ["serde", "serde_derive"]
[dependencies]
serde = { version = "1", optional = true }
serde_derive = { version = "1", optional = true }However, this is not possible since feature names must not conflict with other package names in the manifest. In such a case, I will either have to use a name like with-serde or come up with a creative name for my feature.
Edit: Had forgotten to insert a hyperlink