Struct rustdoc_json_types::Discriminant
source · [−]Fields
expr: String
The expression that produced the discriminant.
Unlike value
, this preserves the original formatting (eg suffixes,
hexadecimal, and underscores), making it unsuitable to be machine
interpreted.
In some cases, when the value is to complex, this may be "{ _ }"
.
When this occurs is unstable, and may change without notice.
value: String
The numerical value of the discriminant. Stored as a string due to
JSON’s poor support for large integers, and the fact that it would need
to store from i128::MIN
to u128::MAX
.
Trait Implementations
sourceimpl Clone for Discriminant
impl Clone for Discriminant
sourcefn clone(&self) -> Discriminant
fn clone(&self) -> Discriminant
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresourceimpl Debug for Discriminant
impl Debug for Discriminant
sourceimpl<'de> Deserialize<'de> for Discriminant
impl<'de> Deserialize<'de> for Discriminant
sourcefn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
sourceimpl Hash for Discriminant
impl Hash for Discriminant
sourceimpl PartialEq<Discriminant> for Discriminant
impl PartialEq<Discriminant> for Discriminant
sourcefn eq(&self, other: &Discriminant) -> bool
fn eq(&self, other: &Discriminant) -> bool
sourceimpl Serialize for Discriminant
impl Serialize for Discriminant
impl Eq for Discriminant
impl StructuralEq for Discriminant
impl StructuralPartialEq for Discriminant
Auto Trait Implementations
impl RefUnwindSafe for Discriminant
impl Send for Discriminant
impl Sync for Discriminant
impl Unpin for Discriminant
impl UnwindSafe for Discriminant
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
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: 48 bytes