This commit is contained in:
2026-04-04 11:34:54 +08:00
parent ee54ab8895
commit b1b886229b
34 changed files with 1811 additions and 4222 deletions
+5 -8
View File
@@ -1,18 +1,15 @@
#![allow(dead_code)]
use fix::error::{Result, Source};
use fix::runtime::Runtime;
use fix::value::Value;
use fix::Evaluator;
use fix_common::Value;
use fix_error::{Result, Source};
pub fn eval(expr: &str) -> Value {
Runtime::new()
.unwrap()
Evaluator::new()
.eval(Source::new_eval(expr.into()).unwrap())
.unwrap()
}
pub fn eval_result(expr: &str) -> Result<Value> {
Runtime::new()
.unwrap()
.eval(Source::new_eval(expr.into()).unwrap())
Evaluator::new().eval(Source::new_eval(expr.into()).unwrap())
}