Enum evaltrees::repl::ReplCommand [−][src]
pub enum ReplCommand { Decl(CstDecl), Evaluator(fn(_: Vec<Decl<()>>) -> Box<Evaluator>), Expr(Expr), Help, List, PrintStyle(PrintStyle), Quit, Reset, Typeof(Expr), }
A command entered at the REPL.
Variants
Decl(CstDecl)
Adds a new declaration.
Evaluator(fn(_: Vec<Decl<()>>) -> Box<Evaluator>)
Sets the function used to construct an evaluator.
Expr(Expr)
Evaluates an expression.
Help
Prints a help menu.
List
Lists all declarations.
PrintStyle(PrintStyle)
Changes the print style.
Quit
Quits the REPL.
Reset
Clears all declarations from the REPL.
Typeof(Expr)
Gets the type of an expression.
Methods
impl ReplCommand
[src]
impl ReplCommand
Trait Implementations
impl FromStr for ReplCommand
[src]
impl FromStr for ReplCommand
type Err = ParseError<usize, String, &'static str>
The associated error which can be returned from parsing.
fn from_str(
s: &str
) -> Result<ReplCommand, ParseError<usize, String, &'static str>>
[src]
fn from_str(
s: &str
) -> Result<ReplCommand, ParseError<usize, String, &'static str>>
Parses a string s
to return a value of this type. Read more
impl Clone for ReplCommand
[src]
impl Clone for ReplCommand
fn clone(&self) -> ReplCommand
[src]
fn clone(&self) -> ReplCommand
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
1.0.0
[src]Performs copy-assignment from source
. Read more
impl Debug for ReplCommand
[src]
impl Debug for ReplCommand
fn fmt(&self, f: &mut Formatter) -> Result
[src]
fn fmt(&self, f: &mut Formatter) -> Result
Formats the value using the given formatter. Read more
impl PartialEq for ReplCommand
[src]
impl PartialEq for ReplCommand
fn eq(&self, other: &ReplCommand) -> bool
[src]
fn eq(&self, other: &ReplCommand) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &ReplCommand) -> bool
[src]
fn ne(&self, other: &ReplCommand) -> bool
This method tests for !=
.
Auto Trait Implementations
impl Send for ReplCommand
impl Send for ReplCommand
impl Sync for ReplCommand
impl Sync for ReplCommand