31

I have a written a bit of rust by now, but one problem I always seem to encounter it that the features a create supports never seem to be documented. Neither what features are available, what they each do or which are default. Is that really the case, or am I missing something?

I constantly seem to include something from the docs, only to be told by the compiler that it does not exist, and then I have to open the source for the create to figure out if it's hidden behind a feature flag.

Also, is it really true that I can't disable a single feature from the default set, without having to copy the default list and manually removing it?

you are viewing a single comment's thread
view the rest of the comments
[-] RunAwayFrog@sh.itjust.works 2 points 1 year ago

are there any hurdles or other good reasons to not just adding this to every create?

I'm no expert. But my guess would be that many crate authors may simply not be aware of this feature. It wasn't always there, and it's still unstable. You would have to reach the "Unstable features" page of the rustdoc book to know about it.

Or maybe some know about it, but don't want to use an unstable feature, or are just waiting for it to possibly automatically work without any modifications.

Of course, I would assume none of this applies to the embassy devs. That Cargo.toml file has a flavors field, which is something I've never seen before ๐Ÿ˜‰ So, I'm assuming they are way more knowledgable (and up-to-date) about the Rust ecosystem than me.

this post was submitted on 14 Aug 2023
31 points (97.0% liked)

Rust

5744 readers
44 users here now

Welcome to the Rust community! This is a place to discuss about the Rust programming language.

Wormhole

!performance@programming.dev

Credits

  • The icon is a modified version of the official rust logo (changing the colors to a gradient and black background)

founded 1 year ago
MODERATORS