pub enum RequestedFeatures {
CliFeatures(CliFeatures),
DepFeatures {
features: Rc<BTreeSet<InternedString>>,
uses_default_features: bool,
},
}
Expand description
Features flags requested for a package.
This should be cheap and fast to clone, it is used in the resolver for various caches.
This is split into enum variants because the resolver needs to handle features coming from different places (command-line and dependency declarations), but those different places have different constraints on which syntax is allowed. This helps ensure that every place dealing with features is properly handling those syntax restrictions.
Variants§
CliFeatures(CliFeatures)
Features requested on the command-line with flags.
DepFeatures
Features specified in a dependency declaration.
Trait Implementations§
Source§impl Clone for RequestedFeatures
impl Clone for RequestedFeatures
Source§fn clone(&self) -> RequestedFeatures
fn clone(&self) -> RequestedFeatures
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for RequestedFeatures
impl Debug for RequestedFeatures
Source§impl Hash for RequestedFeatures
impl Hash for RequestedFeatures
Source§impl PartialEq for RequestedFeatures
impl PartialEq for RequestedFeatures
impl Eq for RequestedFeatures
impl StructuralPartialEq for RequestedFeatures
Auto Trait Implementations§
impl Freeze for RequestedFeatures
impl RefUnwindSafe for RequestedFeatures
impl !Send for RequestedFeatures
impl !Sync for RequestedFeatures
impl Unpin for RequestedFeatures
impl UnwindSafe for RequestedFeatures
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit
)§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key
and return true
if they are equal.§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
§impl<T> Pointable for T
impl<T> Pointable for T
§impl<T> WithSubscriber for T
impl<T> WithSubscriber for T
§fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>where
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>where
S: Into<Dispatch>,
§fn with_current_subscriber(self) -> WithDispatch<Self>
fn with_current_subscriber(self) -> WithDispatch<Self>
Layout§
Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain repr(...)
attributes. Please see the Rust Reference's “Type Layout” chapter for details on type layout guarantees.
Size: 24 bytes
Size for each variant:
CliFeatures
: 23 bytesDepFeatures
: 15 bytes