pub struct TypeExtends {
pub item: TypeId,
pub extends: TypeId,
}Expand description
This if from the type annotation is
Fields§
§item: TypeId§extends: TypeIdImplementations§
Source§impl TypeExtends
impl TypeExtends
Sourcepub fn from_type(rhs: TypeId, types: &TypeStore) -> Result<Self, ()>
pub fn from_type(rhs: TypeId, types: &TypeStore) -> Result<Self, ()>
This does typeof, === and instanceof
Because of type representation and the fact this cannot generate types the following are not covered
- negation. Cannot create
Not - number intrinsincs. Cannot create
LessThan,GreaterThan, etc - has property. Cannot create new object
pub fn equal_to_rhs(&self, rhs: TypeId, types: &TypeStore) -> bool
Trait Implementations§
Source§impl Clone for TypeExtends
impl Clone for TypeExtends
Source§fn clone(&self) -> TypeExtends
fn clone(&self) -> TypeExtends
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for TypeExtends
impl Debug for TypeExtends
impl Copy for TypeExtends
Auto Trait Implementations§
impl Freeze for TypeExtends
impl RefUnwindSafe for TypeExtends
impl Send for TypeExtends
impl Sync for TypeExtends
impl Unpin for TypeExtends
impl UnsafeUnpin for TypeExtends
impl UnwindSafe for TypeExtends
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more