changeset 144:86d097dceebc

Make os9 directives not throw spurious bad operand errors
author lost@l-w.ca
date Sat, 20 Aug 2011 09:59:45 -0600
parents 42a7a16a058f
children d6e9cc4484f6
files lwasm/os9.c
diffstat 1 files changed, 3 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/lwasm/os9.c	Sat Aug 20 00:02:55 2011 -0600
+++ b/lwasm/os9.c	Sat Aug 20 09:59:45 2011 -0600
@@ -71,12 +71,14 @@
 	if (as -> output_format != OUTPUT_OS9)
 	{
 		lwasm_register_error(as, l,  "mod directive only valid for OS9 target");
+		skip_operand(p);
 		return;
 	}
 	
 	if (as -> inmod)
 	{
 		lwasm_register_error(as, l,  "Already in a module!");
+		skip_operand(p);
 		return;
 	}
 
@@ -168,6 +170,7 @@
 
 PARSEFUNC(pseudo_parse_emod)
 {
+	skip_operand(p);
 	if (as -> output_format != OUTPUT_OS9)
 	{
 		lwasm_register_error(as, l, "emod directive only valid for OS9 target");