[−][src]Struct evcxr::EvalContext
Fields
preserve_vars_on_panic: bool
Implementations
impl EvalContext
[src]
pub fn new() -> Result<(EvalContext, EvalContextOutputs), Error>
[src]
pub fn with_subprocess_command(
subprocess_command: Command
) -> Result<(EvalContext, EvalContextOutputs), Error>
[src]
subprocess_command: Command
) -> Result<(EvalContext, EvalContextOutputs), Error>
pub fn eval(&mut self, code: &str) -> Result<EvalOutputs, Error>
[src]
Evaluates the supplied Rust code.
pub fn time_passes(&self) -> bool
[src]
pub fn set_time_passes(&mut self, value: bool)
[src]
pub fn opt_level(&self) -> &str
[src]
pub fn set_opt_level(&mut self, level: &str) -> Result<(), Error>
[src]
pub fn output_format(&self) -> &str
[src]
pub fn set_output_format(&mut self, output_format: String)
[src]
pub fn set_sccache(&mut self, enabled: bool) -> Result<(), Error>
[src]
pub fn sccache(&self) -> bool
[src]
pub fn set_error_format(&mut self, format_str: &str) -> Result<(), Error>
[src]
pub fn error_format(&self) -> &str
[src]
pub fn error_format_trait(&self) -> &str
[src]
pub fn set_linker(&mut self, linker: String)
[src]
pub fn linker(&self) -> &str
[src]
pub fn add_extern_crate(
&mut self,
name: String,
config: String
) -> Result<EvalOutputs, Error>
[src]
&mut self,
name: String,
config: String
) -> Result<EvalOutputs, Error>
pub fn add_dep(&mut self, name: &str, config: &str) -> Result<(), Error>
[src]
Adds a crate dependency with the specified name and configuration. Actual compilation is deferred until the next call to eval. If that call fails, then this dependency will be reverted. If you want to compile straight away and ensure that the change is committed, then follow this call with a call to eval("");
pub fn debug_mode(&self) -> bool
[src]
pub fn set_debug_mode(&mut self, debug_mode: bool)
[src]
pub fn variables_and_types(&self) -> impl Iterator<Item = (&str, &str)>
[src]
pub fn defined_item_names(&self) -> impl Iterator<Item = &str>
[src]
pub fn clear(&mut self) -> Result<(), Error>
[src]
Auto Trait Implementations
impl !RefUnwindSafe for EvalContext
impl Send for EvalContext
impl !Sync for EvalContext
impl Unpin for EvalContext
impl !UnwindSafe for EvalContext
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>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,