Struct mm0b_parser::Type [−][src]
#[repr(C)]pub struct Type(_);
An argument binder in a term/def or axiom/theorem.
- Bit 63 (the high bit of the high byte) is 1 if this is a bound variable.
- Bits 56-62 (the low 7 bits of the high byte) give the sort of the variable.
- Bits 0-55 (the low 7 bytes) are a bitset giving the set of bound variables earlier in the list that this variable is allowed to depend on.
Implementations
impl Type
[src]
pub fn into_inner(self) -> u64
[src]
Get the u64 comprising a type
#[must_use]pub fn new_of_sort(sort_num: u8) -> Self
[src]
Make a new Type
of sort sort_num
#[must_use]pub fn new(bound: bool) -> Self
[src]
A brand new Type
; bool indicates whether it’s bound.
pub fn add_sort(&mut self, sort_id: SortId)
[src]
Annotate a Type
with a sort.
Since types are often built incrementally, you may have built a “blank”
type that you knew was bound, but you’ll only know it’s sort later.
This is how you add the sort. If the Type
already had a sort,
it’s overwritten by sort_id
.
pub fn add_dep(&mut self, bv_idx: u64)
[src]
Add a dependency on bv_idx
#[must_use]pub fn depends_on(self, bv_idx: u64) -> bool
[src]
Does this type depend on the bth bound variable?
This is 0 indexed.
#[must_use]pub fn bound(self) -> bool
[src]
True if this argument is a bound variable.
#[must_use]pub fn sort(self) -> SortId
[src]
The sort of this variable.
#[must_use]pub fn bound_digit(self) -> Option<u64>
[src]
If this is the type of a bound variable, return a u64 whose only activated bit is the bit indicating which bv it is.
#[must_use]pub fn bound_pos(self) -> Option<u64>
[src]
The POSITION (1 - 55) of this bound variable, NOT the literal u64.
#[must_use]pub fn has_deps(self) -> bool
[src]
Does this Type
have dependencies?
#[must_use]pub fn deps(self) -> Option<u64>
[src]
If this is a regular/not-bound variable, return a u64 whose only activated bits are the ones marking the bvs on which it depends.
#[must_use]pub fn deps_unchecked(self) -> u64
[src]
Assuming this is a regular/not-bound variable, return a u64 whose only activated bits are the ones marking the bvs on which it depends.
#[must_use]pub fn high_bit(self) -> Self
[src]
Get the high bit only, which holds the boundedness and the sort.
#[must_use]pub fn disjoint(self, other: Self) -> bool
[src]
Are these two types totally bitwise-disjoint
Trait Implementations
impl BitAnd<Type> for Type
[src]
type Output = Self
The resulting type after applying the &
operator.
fn bitand(self, rhs: Self) -> Self::Output
[src]
impl BitAndAssign<Type> for Type
[src]
fn bitand_assign(&mut self, other: Self)
[src]
impl BitOr<Type> for Type
[src]
type Output = Self
The resulting type after applying the |
operator.
fn bitor(self, rhs: Self) -> Self::Output
[src]
impl BitOrAssign<Type> for Type
[src]
fn bitor_assign(&mut self, other: Self)
[src]
impl Clone for Type
[src]
impl Copy for Type
[src]
impl Debug for Type
[src]
impl Default for Type
[src]
impl Eq for Type
[src]
impl From<u64> for Type
[src]
impl FromBytes for Type
[src]
fn only_derive_is_allowed_to_implement_this_trait() where
Self: Sized,
[src]
Self: Sized,
impl Hash for Type
[src]
fn hash<__H: Hasher>(&self, state: &mut __H)
[src]
pub fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0[src]
H: Hasher,
impl Not for Type
[src]
type Output = Type
The resulting type after applying the !
operator.
fn not(self) -> Self::Output
[src]
impl PartialEq<Type> for Type
[src]
impl StructuralEq for Type
[src]
impl StructuralPartialEq for Type
[src]
impl Unaligned for Type
[src]
fn only_derive_is_allowed_to_implement_this_trait() where
Self: Sized,
[src]
Self: Sized,
Auto Trait Implementations
impl RefUnwindSafe for Type
impl Send for Type
impl Sync for Type
impl Unpin for Type
impl UnwindSafe for Type
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,