summaryrefslogtreecommitdiffstats
path: root/src/vhd2vl.y
diff options
context:
space:
mode:
authorLarry Doolittle <ldoolitt@recycle.lbl.gov>2017-11-23 22:26:44 -0800
committerLarry Doolittle <ldoolitt@recycle.lbl.gov>2017-11-23 22:26:44 -0800
commit98b734cadd8c73940d46e1d86916c7c0b9b41de7 (patch)
tree0a5b0ab891fd462fa0ed015031e25529923028a4 /src/vhd2vl.y
parenta043b124b5390380638eeec56fb143d2670af85c (diff)
downloadvhdl2vl-98b734cadd8c73940d46e1d86916c7c0b9b41de7.tar.gz
vhdl2vl-98b734cadd8c73940d46e1d86916c7c0b9b41de7.zip
Turn off debug prints and fix warnings
Diffstat (limited to 'src/vhd2vl.y')
-rw-r--r--src/vhd2vl.y12
1 files changed, 7 insertions, 5 deletions
diff --git a/src/vhd2vl.y b/src/vhd2vl.y
index 46deefc..0a20896 100644
--- a/src/vhd2vl.y
+++ b/src/vhd2vl.y
@@ -302,10 +302,13 @@ slist *addind(slist *sl){
return sl;
}
+#define DEBUG_RANGE 0
slist *addpar_snug(slist *sl, vrange *v){
- fprintf(stderr,"addpar_snug %d: ", v->sizeval);
- fslprint(stderr, v->size_expr);
- fprintf(stderr,"\n");
+ if (DEBUG_RANGE) {
+ fprintf(stderr,"addpar_snug %d: ", v->sizeval);
+ fslprint(stderr, v->size_expr);
+ fprintf(stderr,"\n");
+ }
if(v->nlo != NULL) { /* indexes are simple expressions */
sl=addtxt(sl,"[");
if(v->nhi != NULL){
@@ -425,7 +428,6 @@ char *strgrab(char*s, size_t len)
}
/* s1 is the longer string, s2 is the shorter string */
-#define DEBUG_RANGE 1
char *string_check_diff(char *s1, char *s2)
{
size_t llen = strlen(s1);
@@ -1194,11 +1196,11 @@ type : BIT {
/* using expr instead of simple_expr here makes the grammar ambiguous (why?) */
vec_range : simple_expr updown simple_expr {
+ char *range_diff = 0;
$$=new_vrange(tVRANGE);
$$->nhi=$1->sl;
$$->nlo=$3->sl;
$$->sizeval = -1; /* undefined size */
- char *range_diff = 0;
/* Here is where we may want to analyze the two expressions to
* see if they have a simple (possibly constant) difference.
* For now, here's an option to visualise their data structures.
OpenPOWER on IntegriCloud