pub struct Bool<'st>(/* private fields */);
Expand description
A Bool
is a term containing a
boolean. You can read more
here..
Implementations§
Source§impl<'st> Bool<'st>
impl<'st> Bool<'st>
Sourcepub fn implies(self, other: Bool<'st>) -> Bool<'st>
pub fn implies(self, other: Bool<'st>) -> Bool<'st>
Construct the term expressing (==> self other)
.
The value of the returned boolean is true if:
self
is false- or
other
is true
Sourcepub fn ite<T: Sorted<'st> + From<(STerm<'st>, Sort<'st>)>>(
self,
then: T,
otherwise: T,
) -> T
pub fn ite<T: Sorted<'st> + From<(STerm<'st>, Sort<'st>)>>( self, then: T, otherwise: T, ) -> T
Construct the term expressing (ite self then otherwise)
.
This is similar to the ternary condition operator, and an if statement:
- C-style notation:
self ? then : otherwise
- Rust notation:
if self { then } else { otherwise }
Trait Implementations§
Source§impl<'st, R> BitAndAssign<R> for Bool<'st>where
R: IntoWithStorage<'st, Bool<'st>>,
impl<'st, R> BitAndAssign<R> for Bool<'st>where
R: IntoWithStorage<'st, Bool<'st>>,
Source§fn bitand_assign(&mut self, rhs: R)
fn bitand_assign(&mut self, rhs: R)
Performs the
&=
operation. Read moreSource§impl<'st, R> BitOrAssign<R> for Bool<'st>where
R: IntoWithStorage<'st, Bool<'st>>,
impl<'st, R> BitOrAssign<R> for Bool<'st>where
R: IntoWithStorage<'st, Bool<'st>>,
Source§fn bitor_assign(&mut self, rhs: R)
fn bitor_assign(&mut self, rhs: R)
Performs the
|=
operation. Read moreSource§impl<'st, R> BitXorAssign<R> for Bool<'st>where
R: IntoWithStorage<'st, Bool<'st>>,
impl<'st, R> BitXorAssign<R> for Bool<'st>where
R: IntoWithStorage<'st, Bool<'st>>,
Source§fn bitxor_assign(&mut self, rhs: R)
fn bitxor_assign(&mut self, rhs: R)
Performs the
^=
operation. Read moreSource§impl<'st> IntoWithStorage<'st, Bool<'st>> for Const<'st, Bool<'st>>
impl<'st> IntoWithStorage<'st, Bool<'st>> for Const<'st, Bool<'st>>
Source§fn into_with_storage(self, _st: &'st Storage) -> Bool<'st>
fn into_with_storage(self, _st: &'st Storage) -> Bool<'st>
Construct a
STerm
with the presence of Storage
Source§impl<'st> IntoWithStorage<'st, Bool<'st>> for bool
impl<'st> IntoWithStorage<'st, Bool<'st>> for bool
Source§fn into_with_storage(self, st: &'st Storage) -> Bool<'st>
fn into_with_storage(self, st: &'st Storage) -> Bool<'st>
Construct a
STerm
with the presence of Storage
Source§impl<'st> StaticSorted<'st> for Bool<'st>
impl<'st> StaticSorted<'st> for Bool<'st>
Source§type Inner = Bool<'st>
type Inner = Bool<'st>
The inner type of the term. This is used for
Const<'st, T>
where the inner type is T
.impl<'st> Copy for Bool<'st>
Auto Trait Implementations§
impl<'st> Freeze for Bool<'st>
impl<'st> !RefUnwindSafe for Bool<'st>
impl<'st> !Send for Bool<'st>
impl<'st> !Sync for Bool<'st>
impl<'st> Unpin for Bool<'st>
impl<'st> !UnwindSafe for Bool<'st>
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 moreSource§impl<'st, T> IntoWithStorage<'st, T> for T
impl<'st, T> IntoWithStorage<'st, T> for T
Source§fn into_with_storage(self, _st: &'st Storage) -> T
fn into_with_storage(self, _st: &'st Storage) -> T
Construct a
STerm
with the presence of Storage
Source§impl<'st, T> Sorted<'st> for Twhere
T: StaticSorted<'st>,
impl<'st, T> Sorted<'st> for Twhere
T: StaticSorted<'st>,
Source§type Inner = <T as StaticSorted<'st>>::Inner
type Inner = <T as StaticSorted<'st>>::Inner
The inner type of the term. This is used for
Const<'st, T>
where the inner type is T
.Source§fn sterm(self) -> STerm<'st>
fn sterm(self) -> STerm<'st>
Constructy the smtlib AST representation of the term with associated
storage.
Source§fn from_dynamic(d: Dynamic<'st>) -> Self
fn from_dynamic(d: Dynamic<'st>) -> Self
Casts a dynamically typed term into a concrete type
Source§fn try_from_dynamic(d: Dynamic<'st>) -> Option<Self>
fn try_from_dynamic(d: Dynamic<'st>) -> Option<Self>
Casts a dynamically typed term into a concrete type iff the dynamic sort
matches
Source§fn into_dynamic(self) -> Dynamic<'st>
fn into_dynamic(self) -> Dynamic<'st>
Casts the term into a dynamic term which looses static types and stores
the sort dynamically.
Source§fn _eq(self, other: impl IntoWithStorage<'st, Self::Inner>) -> Bool<'st>
fn _eq(self, other: impl IntoWithStorage<'st, Self::Inner>) -> Bool<'st>
Construct the term representing
(= self other)