changeset 177:f8b07153abc4

Make 'imm8' instructions actually complain about a bad operand if no # is present
author lost@l-w.ca
date Wed, 07 Sep 2011 21:59:10 -0600
parents 03f425c6c39c
children 35f7ce3ef857
files lwasm/insn_gen.c
diffstat 1 files changed, 4 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/lwasm/insn_gen.c	Wed Sep 07 21:49:35 2011 -0600
+++ b/lwasm/insn_gen.c	Wed Sep 07 21:59:10 2011 -0600
@@ -432,6 +432,10 @@
 		l -> len = OPLEN(instab[l -> insn].ops[0]) + 1;
 		lwasm_save_expr(l, 0, e);
 	}
+	else
+	{
+		lwasm_register_error(as, l, "Bad operand");
+	}
 }
 
 EMITFUNC(insn_emit_imm8)