pub enum TyBasic {
Any,
Name(TyName),
StarlarkValue(TyStarlarkValue),
Iter(ArcTy),
Callable,
Type,
List(ArcTy),
Tuple(TyTuple),
Dict(ArcTy, ArcTy),
Custom(TyCustom),
}
Expand description
Type that is not a union.
Variants§
Any
Type that contain anything
Name(TyName)
A name, represented by "name"
in the Starlark type.
Will never be a type that can be represented by another operation,
e.g. never "list"
because Ty::List
could be used instead.
StarlarkValue(TyStarlarkValue)
Type is handled by StarlarkValue
trait implementation.
Iter(ArcTy)
Iter is a type that supports iteration, only used as arguments to primitive functions. The inner type is applicable for each iteration element.
Callable
typing.Callable
.
Type
type
.
List(ArcTy)
A list.
Tuple(TyTuple)
A tuple. May be empty, to indicate the empty tuple.
Dict(ArcTy, ArcTy)
A dictionary, with key and value types
Custom(TyCustom)
Custom type.
Implementations§
Trait Implementations§
source§impl Allocative for TyBasic
impl Allocative for TyBasic
source§impl Ord for TyBasic
impl Ord for TyBasic
source§impl PartialEq for TyBasic
impl PartialEq for TyBasic
source§impl PartialOrd for TyBasic
impl PartialOrd for TyBasic
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moreimpl Eq for TyBasic
impl StructuralPartialEq for TyBasic
Auto Trait Implementations§
impl !RefUnwindSafe for TyBasic
impl Send for TyBasic
impl Sync for TyBasic
impl Unpin for TyBasic
impl !UnwindSafe for TyBasic
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
§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§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
Compare self to
key
and return true
if they are equal.