[][src]Enum kontroli::Command

pub enum Command<Id, Intro, Rule> {
    Intro(Id, Intro),
    Rules(Vec<Rule>),
}

Signature-changing command.

Variants

Intro(Id, Intro)

Introduce a new name

Rules(Vec<Rule>)

Add rewrite rules

Implementations

impl Command<String, Intro<Box<Term>, Box<Term>>, Rule<Arg<String, Option<Box<Term>>>, Term, Term>>[src]

pub fn scope<'s>(self, syms: &Symbols<'s>) -> Result<Command<'s, String>, Error>[src]

impl<'s> Command<Id, Intro<RTerm<'s>, RTerm<'s>>, Rule<String, Application<Symbol<'s>, Pattern<Symbol<'s>>>, RTerm<'s>>>[src]

pub fn parse(i: &str, syms: &Symbols<'s>) -> Result<Self, KoError>[src]

Parse a command and scope it. Used for testing.

Trait Implementations

impl<Id: Clone, Intro: Clone, Rule: Clone> Clone for Command<Id, Intro, Rule>[src]

impl<Id: Display, Intro: Display, Rule: Display> Display for Command<Id, Intro, Rule>[src]

Auto Trait Implementations

impl<Id, Intro, Rule> RefUnwindSafe for Command<Id, Intro, Rule> where
    Id: RefUnwindSafe,
    Intro: RefUnwindSafe,
    Rule: RefUnwindSafe

impl<Id, Intro, Rule> Send for Command<Id, Intro, Rule> where
    Id: Send,
    Intro: Send,
    Rule: Send

impl<Id, Intro, Rule> Sync for Command<Id, Intro, Rule> where
    Id: Sync,
    Intro: Sync,
    Rule: Sync

impl<Id, Intro, Rule> Unpin for Command<Id, Intro, Rule> where
    Id: Unpin,
    Intro: Unpin,
    Rule: Unpin

impl<Id, Intro, Rule> UnwindSafe for Command<Id, Intro, Rule> where
    Id: UnwindSafe,
    Intro: UnwindSafe,
    Rule: UnwindSafe

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.