From 81c5a34211e2fefa2b59ebd0382d1de3ec1b7d2a Mon Sep 17 00:00:00 2001 From: ConnorSkees <39542938+ConnorSkees@users.noreply.github.com> Date: Mon, 23 Mar 2020 15:25:26 -0400 Subject: [PATCH] function-exists allows 2 args --- src/builtin/meta.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/builtin/meta.rs b/src/builtin/meta.rs index 6c67609..e58dac9 100644 --- a/src/builtin/meta.rs +++ b/src/builtin/meta.rs @@ -116,7 +116,7 @@ pub(crate) fn register(f: &mut HashMap) { f.insert( "function-exists".to_owned(), Box::new(|args, scope| { - max_args!(args, 1); + max_args!(args, 2); match arg!(args, 0, "name") { Value::Ident(s, _) => Ok(Value::bool( scope.fn_exists(&s) || GLOBAL_FUNCTIONS.contains_key(&s),