summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorRodrigo Alejandro Melo <rodrigomelo9@gmail.com>2017-02-19 12:18:05 -0300
committerRodrigo Alejandro Melo <rodrigomelo9@gmail.com>2017-02-19 12:22:29 -0300
commit4e42da408f9ddbd518601fcc6d1a0f50c941ec5e (patch)
treec1578ea9d936124b456651c23d2d82d0f88eae64 /src
parent3c72037ab47fb87c525b2c7f741b8d5d1614a30b (diff)
downloadvhdl2vl-4e42da408f9ddbd518601fcc6d1a0f50c941ec5e.tar.gz
vhdl2vl-4e42da408f9ddbd518601fcc6d1a0f50c941ec5e.zip
Promoted unsupported BASED NUMBER from warning to error
Because the resulting verilog had the unsupported notation BASE#NUMBER#. Moreover, the 'ERROR:' string was added when an error is informed.
Diffstat (limited to 'src')
-rw-r--r--src/vhd2vl.y9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/vhd2vl.y b/src/vhd2vl.y
index 5b01483..b019c67 100644
--- a/src/vhd2vl.y
+++ b/src/vhd2vl.y
@@ -1049,7 +1049,7 @@ type : BIT {
if(sg)
$$=sg->range;
else{
- fprintf(stderr,"Undefined type '%s' on line %d\n",$1,lineno);
+ fprintf(stderr,"ERROR: undefined type '%s' on line %d\n",$1,lineno);
YYABORT;
}
}
@@ -1107,7 +1107,7 @@ vec_range : simple_expr updown simple_expr {
if(sg) {
$$ = sg->range;
} else {
- fprintf(stderr,"Undefined range \"%s'range\" on line %d\n",$1,lineno);
+ fprintf(stderr,"ERROR: undefined range \"%s'range\" on line %d\n",$1,lineno);
YYABORT;
}
}
@@ -2105,7 +2105,8 @@ expr : signal {
break;
default:
sprintf(natval,"%d#%s#",$1,$2);
- fprintf(stderr,"Warning on line %d: Can't translate based number %s (only bases of 2, 8, 10, and 16 are translatable)\n",lineno,natval);
+ fprintf(stderr,"ERROR: can't translate based number %s (only bases of 2, 8, 10, and 16 are translatable) on line %d\n",natval,lineno);
+ YYABORT;
}
e->sl=addtxt(NULL,natval);
$$=e;
@@ -2329,7 +2330,7 @@ simple_expr : signal {
e->sl=addwrap("(",sg->range->nhi,")"); /* XXX left vs. high? */
$$=e;
} else {
- fprintf(stderr,"Undefined left \"%s'left\" on line %d\n",$1,lineno);
+ fprintf(stderr,"ERROR: undefined left \"%s'left\" on line %d\n",$1,lineno);
YYABORT;
}
}
OpenPOWER on IntegriCloud