pub enum ValueKind {
Function {
generics: Vec<String>,
params: Vec<Param>,
ret: Type,
type_predicate: Option<TypePredicate>,
doc: Option<DocComment>,
},
Let {
ty: Type,
doc: Option<DocComment>,
},
Const {
ty: Type,
doc: Option<DocComment>,
},
}Variants§
Function
Fields
§
generics: Vec<String>Names appear inside params/ret as Type::Var(name), resolved per call site by TypeParamSubstitution.
§
type_predicate: Option<TypePredicate>Type-guard (x is T); inferer copies this into Type::Function at each reference site.
§
doc: Option<DocComment>Let
Fields
§
ty: TypeResolved type of the binding. Type::Error when the annotation
was missing or unresolvable — the originating diagnostic is in
the diagnostics list.
§
doc: Option<DocComment>Const
Trait Implementations§
Source§impl<'de> Deserialize<'de> for ValueKind
impl<'de> Deserialize<'de> for ValueKind
Source§fn 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>,
Deserialize this value from the given Serde deserializer. Read more
impl StructuralPartialEq for ValueKind
Auto Trait Implementations§
impl Freeze for ValueKind
impl RefUnwindSafe for ValueKind
impl Send for ValueKind
impl Sync for ValueKind
impl Unpin for ValueKind
impl UnsafeUnpin for ValueKind
impl UnwindSafe for ValueKind
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
Mutably borrows from an owned value. Read more