From 6cea0d97c24a15fa128b0116d1b9926f3f7ff814 Mon Sep 17 00:00:00 2001 From: Christopher George Date: Wed, 25 Sep 2019 15:09:36 -0400 Subject: [PATCH] =?UTF-8?q?Call=20error()=20on=20invalid=20number=20of=20a?= =?UTF-8?q?rguments=20instead=20of=20just=20throwing=20=E2=80=A6=20(#86)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- hscript/Interp.hx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hscript/Interp.hx b/hscript/Interp.hx index 4468257..a9dc5fe 100644 --- a/hscript/Interp.hx +++ b/hscript/Interp.hx @@ -404,7 +404,7 @@ class Interp { if( args.length < minParams ) { var str = "Invalid number of parameters. Got " + args.length + ", required " + minParams; if( name != null ) str += " for function '" + name+"'"; - throw str; + error(ECustom(str)); } // make sure mandatory args are forced var args2 = [];