pub enum Term {
Var(String),
Bool(bool),
Int(i64),
App {
function: String,
args: Vec<Term>,
},
Eq(Box<Term>, Box<Term>),
And(Vec<Term>),
Or(Vec<Term>),
Not(Box<Term>),
Implies(Box<Term>, Box<Term>),
}Expand description
Backend-agnostic term language for proof obligations.
Variants§
Var(String)
Bool(bool)
Int(i64)
App
Eq(Box<Term>, Box<Term>)
And(Vec<Term>)
Or(Vec<Term>)
Not(Box<Term>)
Implies(Box<Term>, Box<Term>)
Implementations§
Source§impl Term
impl Term
pub fn var(name: impl Into<String>) -> Term
pub fn bool(value: bool) -> Term
pub fn int(value: i64) -> Term
pub fn app( function: impl Into<String>, args: impl IntoIterator<Item = Term>, ) -> Term
pub fn eq(left: Term, right: Term) -> Term
pub fn and(terms: impl IntoIterator<Item = Term>) -> Term
pub fn or(terms: impl IntoIterator<Item = Term>) -> Term
pub fn negate(term: Term) -> Term
pub fn implies(lhs: Term, rhs: Term) -> Term
Trait Implementations§
impl Eq for Term
impl StructuralPartialEq for Term
Auto Trait Implementations§
impl Freeze for Term
impl RefUnwindSafe for Term
impl Send for Term
impl Sync for Term
impl Unpin for Term
impl UnsafeUnpin for Term
impl UnwindSafe for Term
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