Enum resolution_prover::ClausePart[][src]

pub enum ClausePart {
    Term(String),
    NegatedTerm(String),
}

A term or negated term that is part of a clause.

For example, p and ~q can be represented as the following.

let p = resolution_prover::ClausePart::Term("p".to_string());

let not_q = resolution_prover::ClausePart::NegatedTerm("q".to_string());

Variants

Methods

impl ClausePart
[src]

Returns the negated version of the clause part.

let clausePart = resolution_prover::ClausePart::Term("p".to_string());

let neg = clausePart.negate();

let expected_1 =
    resolution_prover::ClausePart::NegatedTerm("p".to_string());

assert_eq!(neg, expected_1);

let double_neg = neg.negate();

assert_eq!(double_neg, clausePart);

Trait Implementations

impl Clone for ClausePart
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl Debug for ClausePart
[src]

Formats the value using the given formatter. Read more

impl Eq for ClausePart
[src]

impl Hash for ClausePart
[src]

Feeds this value into the given [Hasher]. Read more

Feeds a slice of this type into the given [Hasher]. Read more

impl PartialEq for ClausePart
[src]

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

Auto Trait Implementations

impl Send for ClausePart

impl Sync for ClausePart