aboutsummaryrefslogtreecommitdiff
path: root/src/prc1/from.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/prc1/from.c')
-rw-r--r--src/prc1/from.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/prc1/from.c b/src/prc1/from.c
index b9cb99e..838d1de 100644
--- a/src/prc1/from.c
+++ b/src/prc1/from.c
@@ -1,5 +1,6 @@
#include "from.h"
#include "cgen.h"
+#include "dbg.h"
#include "fn.h"
#include "errloc.h"
#include "stmt.h"
@@ -236,8 +237,7 @@ static int finalize(struct prv *p, struct fn *fn, struct from *fr)
fn->stmts = s;
pos->seq = pos->stseq = stmts;
pos->step = stmts->steps;
- fprintf(stderr, ", iterator %s, block index %zu\n", fr->var->tk->s,
- bl[fn->nblocks - 1]);
+ dbg(", iterator %s, block index %zu\n", fr->var->tk->s, bl[fn->nblocks - 1]);
return 0;
}
@@ -297,7 +297,7 @@ int from(const struct lex *l, struct prv *p)
|| !(fr.var = tmp_create(fn, t)))
return -1;
- fprintf(stderr, "\t\tadding from statement [%s, %s]", start->s, end->s);
+ dbg("\t\tadding from statement [%s, %s]", start->s, end->s);
if (finalize(p, fn, &fr))
return -1;
@@ -341,8 +341,8 @@ int from_id(const struct lex *l, struct prv *p)
|| checkvar(fn, var, &fr))
return -1;
- fprintf(stderr, "\t\tadding from statement [%s, %s] using %s",
- start->s, end->s, var->s);
+ dbg("\t\tadding from statement [%s, %s] using %s", start->s, end->s,
+ var->s);
if (finalize(p, fn, &fr))
return -1;