Enum rustc::middle::resolve_lifetime::Set1
[−]
[src]
pub enum Set1<T> { Empty, One(T), Many, }
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
A set containing, at most, one known element.
If two distinct values are inserted into a set, then it
becomes Many
, which can be used to detect ambiguities.
Variants
Empty
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
One(T)
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
Many
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
Methods
impl<T: PartialEq> Set1<T>
[src]
pub fn insert(&mut self, value: T)
[src]
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
Trait Implementations
impl<'gcx, T> HashStable<StableHashingContext<'gcx>> for Set1<T> where
T: HashStable<StableHashingContext<'gcx>>,
[src]
T: HashStable<StableHashingContext<'gcx>>,
fn hash_stable<W: StableHasherResult>(
&self,
hcx: &mut StableHashingContext<'gcx>,
hasher: &mut StableHasher<W>
)
[src]
&self,
hcx: &mut StableHashingContext<'gcx>,
hasher: &mut StableHasher<W>
)
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
impl<T: Copy> Copy for Set1<T>
[src]
impl<T: Clone> Clone for Set1<T>
[src]
fn clone(&self) -> Set1<T>
[src]
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl<T: PartialEq> PartialEq for Set1<T>
[src]
fn eq(&self, __arg_0: &Set1<T>) -> bool
[src]
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, __arg_0: &Set1<T>) -> bool
[src]
This method tests for !=
.
impl<T: Eq> Eq for Set1<T>
[src]
impl<T: Encodable> Encodable for Set1<T>
[src]
fn encode<__ST: Encoder>(&self, __arg_0: &mut __ST) -> Result<(), __ST::Error>
[src]
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
impl<T: Decodable> Decodable for Set1<T>
[src]
fn decode<__DT: Decoder>(__arg_0: &mut __DT) -> Result<Set1<T>, __DT::Error>
[src]
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?