Allow non-Dynamic in return_raw.

This commit is contained in:
Stephen Chung
2021-03-22 11:18:09 +08:00
parent b3bcd7bf79
commit a82f0fc738
23 changed files with 214 additions and 282 deletions

View File

@@ -98,10 +98,7 @@ macro_rules! def_anonymous_fn {
#[inline(always)]
fn create_from_ast(self, ast: AST, entry_point: &str) -> Self::Output {
let fn_name = entry_point.to_string();
Box::new(move |$($par: $par),*| {
self.call_fn(&mut Scope::new(), &ast, &fn_name, ($($par,)*))
})
Box::new(move |$($par),*| self.call_fn(&mut Scope::new(), &ast, &fn_name, ($($par,)*)))
}
#[inline(always)]