summaryrefslogtreecommitdiff
path: root/parser.c
diff options
context:
space:
mode:
authorCharles Crayne <chuck@thor.crayne.org>2008-09-23 21:49:09 -0700
committerCharles Crayne <chuck@thor.crayne.org>2008-09-23 21:49:09 -0700
commit7f596e7aa8774b1c8d9e3fcf6371b5687464568e (patch)
tree8ff154901727d6528bc3d9768844585194b050af /parser.c
parent0af3e7ed3c265082b5b44c7f9f3d04011ec91988 (diff)
downloadnasm-7f596e7aa8774b1c8d9e3fcf6371b5687464568e.tar.gz
Allow value to TIMES to be negative while optimization is in progress
Change the parser to only issue the "TIMES value %d is negative" error message if all optimization passes have completed.
Diffstat (limited to 'parser.c')
-rw-r--r--parser.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/parser.c b/parser.c
index 7e5c9a32..6893c981 100644
--- a/parser.c
+++ b/parser.c
@@ -256,7 +256,7 @@ restart_parse:
result->times = 1L;
} else {
result->times = value->value;
- if (value->value < 0) {
+ if (value->value < 0 && pass0 == 2) {
error(ERR_NONFATAL, "TIMES value %d is negative",
value->value);
result->times = 0;