Move function back to correct file.
This commit is contained in:
parent
344b48ad36
commit
fa41f4faf0
@ -193,9 +193,4 @@ impl Engine {
|
||||
) -> Result<(), Box<EvalAltResult>> {
|
||||
Self::read_file(path).and_then(|contents| self.run_with_scope(scope, &contents))
|
||||
}
|
||||
/// Evaluate a script, returning any error (if any).
|
||||
#[inline(always)]
|
||||
pub fn run(&self, script: &str) -> Result<(), Box<EvalAltResult>> {
|
||||
self.run_with_scope(&mut Scope::new(), script)
|
||||
}
|
||||
}
|
||||
|
@ -7,6 +7,11 @@ use crate::{Engine, EvalAltResult, Scope, AST};
|
||||
use std::prelude::v1::*;
|
||||
|
||||
impl Engine {
|
||||
/// Evaluate a script, returning any error (if any).
|
||||
#[inline(always)]
|
||||
pub fn run(&self, script: &str) -> Result<(), Box<EvalAltResult>> {
|
||||
self.run_with_scope(&mut Scope::new(), script)
|
||||
}
|
||||
/// Evaluate a script with own scope, returning any error (if any).
|
||||
///
|
||||
/// ## Constants Propagation
|
||||
|
Loading…
Reference in New Issue
Block a user