[svn:parrot] r39437 - trunk/compilers/imcc
NotFound at svn.parrot.org
NotFound at svn.parrot.org
Sat Jun 6 20:55:32 UTC 2009
Author: NotFound
Date: Sat Jun 6 20:55:30 2009
New Revision: 39437
URL: https://trac.parrot.org/parrot/changeset/39437
Log:
[imcc] die politely on get_args and other opcodes used without args when compiling pasm
Modified:
trunk/compilers/imcc/parser_util.c
Modified: trunk/compilers/imcc/parser_util.c
==============================================================================
--- trunk/compilers/imcc/parser_util.c Sat Jun 6 20:27:26 2009 (r39436)
+++ trunk/compilers/imcc/parser_util.c Sat Jun 6 20:55:30 2009 (r39437)
@@ -330,7 +330,9 @@
/* in constant */
int dirs = 1;
- if (r[0] == NULL)
+ /* XXX: Maybe the check for n == 0 is the only one required
+ * and the other must be assertions? */
+ if (n == 0 || r[0] == NULL || r[0]->name == NULL)
IMCC_fataly(interp, EXCEPTION_SYNTAX_ERROR,
"The opcode '%s' needs arguments", name);
More information about the parrot-commits
mailing list