pub struct Formula(/* private fields */);Expand description
A formula: an immutable value, cheap to clone and share.
Implementations§
Source§impl Formula
impl Formula
Sourcepub fn is_well_formed(&self) -> bool
pub fn is_well_formed(&self) -> bool
Whether this formula and all its parts are well formed.
Sourcepub fn kind(&self) -> &FormulaKind
pub fn kind(&self) -> &FormulaKind
What the formula is made of.
Sourcepub fn own_errors(&self) -> &[Error]
pub fn own_errors(&self) -> &[Error]
The errors recorded when this node was built, not its parts’.
Sourcepub fn placed(&self, place: Place) -> Formula
pub fn placed(&self, place: Place) -> Formula
The same node, at another place, as Expr::placed.
Sourcepub fn and_all(formulas: impl IntoIterator<Item = Formula>) -> Formula
pub fn and_all(formulas: impl IntoIterator<Item = Formula>) -> Formula
The conjunction of any number of formulas; true when there are none.
Sourcepub fn or_all(formulas: impl IntoIterator<Item = Formula>) -> Formula
pub fn or_all(formulas: impl IntoIterator<Item = Formula>) -> Formula
The disjunction of any number of formulas; false when there are none.
Sourcepub fn quantified(q: Quantifier, decls: Vec<Decl>, body: &Formula) -> Formula
pub fn quantified(q: Quantifier, decls: Vec<Decl>, body: &Formula) -> Formula
q x1: e1, ..., xm: em | body
Sourcepub fn temporal(&self, op: TemporalOp) -> Formula
pub fn temporal(&self, op: TemporalOp) -> Formula
op self, for a unary temporal operator.
Sourcepub fn temporal_binary(&self, op: TemporalBinaryOp, other: &Formula) -> Formula
pub fn temporal_binary(&self, op: TemporalBinaryOp, other: &Formula) -> Formula
self op other, for a binary temporal operator.
Sourcepub fn eventually(&self) -> Formula
pub fn eventually(&self) -> Formula
eventually self
Sourcepub fn historically(&self) -> Formula
pub fn historically(&self) -> Formula
historically self
Sourcepub fn past_depth(&self) -> usize
pub fn past_depth(&self) -> usize
The greatest number of past operators nested in one another (LOGIC.md 13.3).
Sourcepub fn is_temporal(&self) -> bool
pub fn is_temporal(&self) -> bool
Whether the formula has a temporal operator or a prime.
Trait Implementations§
Auto Trait Implementations§
impl Forget for Formula
impl Freeze for Formula
impl Move for Formula
impl RefUnwindSafe for Formula
impl Send for Formula
impl Sync for Formula
impl Unpin for Formula
impl UnsafeUnpin for Formulawhere
*const ArcInner<FormulaNode> is !null: UnsafeUnpin,
PhantomData<ArcInner<FormulaNode>>: UnsafeUnpin,
impl UnwindSafe for Formulawhere
Arc<FormulaNode>: UnwindSafe,
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