[−][src]Struct whitespacers::Interpreter
A whitespace interpreter. This struct provides various strategies for interpreting a whitespace program.
Implementations
impl<'a> Interpreter<'a>
[src]
pub fn new(
program: &'a Program,
options: Options,
input: &'a mut (dyn BufRead + 'a),
output: &'a mut (dyn Write + 'a)
) -> Interpreter<'a>
[src]
program: &'a Program,
options: Options,
input: &'a mut (dyn BufRead + 'a),
output: &'a mut (dyn Write + 'a)
) -> Interpreter<'a>
Construct a new whitespace interpreter from a program, input stream and output stream with the specified options.
pub fn count_with_simple_state(&'a mut self) -> Result<usize, WsError>
[src]
Similar to Interpreter::interpret_with_simple_state but does not have bigint fallback and returns the amount of executed instructions on success.
pub fn interpret_with_simple_state(&'a mut self) -> Result<(), WsError>
[src]
The reference interpreter implementation. It uses simple data structures internally, falling back to bignum-based simple datastructures if values become too large.
pub fn interpret_with_fast_state(&'a mut self) -> Result<(), WsError>
[src]
Interprets the program with optimized data structures, falling back to bignum-based simple datastructures if values become too large.
pub fn interpret_with_bigint_state(&'a mut self) -> Result<(), WsError>
[src]
Interpret the program using only bignum-based simple datastructures. This is slow.
pub fn jit_aot(&mut self) -> Result<(), WsError>
[src]
Use a jit compiler that compiles the entire program in advance to execute the program. It is backed by an optimized datastructure, and will fall back to interpretation in unsafe situations. When values become too large it will fall back to bignum-based interpretation.
pub fn jit_sync(&mut self) -> Result<(), WsError>
[src]
Use a jit compiler that compiles code synchronously while executing the program. It is backed by an optimized datastructure, and will fall back to interpretation in unsafe situations. When values become too large it will fall back to bignum-based interpretation.
pub fn jit_threaded(&mut self) -> Result<(), WsError>
[src]
Use a jit compiler that compiles the program in a separate thread while executing the program. It is backed by an optimized datastructure, and will fall back to interpretation in unsafe situations. When values become too large it will fall back to bignum-based interpretation.
Auto Trait Implementations
impl<'a> !RefUnwindSafe for Interpreter<'a>
impl<'a> !Send for Interpreter<'a>
impl<'a> !Sync for Interpreter<'a>
impl<'a> Unpin for Interpreter<'a>
impl<'a> !UnwindSafe for Interpreter<'a>
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,