remove test version of Context.eval_with()
This commit is contained in:
parent
f39306e3d6
commit
1074adb9e7
1 changed files with 0 additions and 16 deletions
|
@ -355,7 +355,6 @@ impl Context {
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(not(test))]
|
|
||||||
pub fn eval_with(
|
pub fn eval_with(
|
||||||
&self,
|
&self,
|
||||||
Expression {
|
Expression {
|
||||||
|
@ -368,21 +367,6 @@ impl Context {
|
||||||
instruction.eval(slab, ns)
|
instruction.eval(slab, ns)
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(test)]
|
|
||||||
pub fn eval_with(
|
|
||||||
&self,
|
|
||||||
Expression {
|
|
||||||
from,
|
|
||||||
instruction,
|
|
||||||
slab,
|
|
||||||
}: &Expression,
|
|
||||||
ns: &mut (impl EvalNamespace + Debug),
|
|
||||||
) -> Result<f64, fasteval::Error> {
|
|
||||||
let result = instruction.eval(slab, ns)?;
|
|
||||||
println!("expression {from}\twith values {ns:?}\t equals {result}");
|
|
||||||
Ok(result)
|
|
||||||
}
|
|
||||||
|
|
||||||
pub fn render(&mut self, n: Option<u8>) -> Result<Vec<f64>, CompilerError> {
|
pub fn render(&mut self, n: Option<u8>) -> Result<Vec<f64>, CompilerError> {
|
||||||
let curr_t = *self.get('t')?;
|
let curr_t = *self.get('t')?;
|
||||||
if let Some(note) = n {
|
if let Some(note) = n {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue