diff options
| author | 2022-08-13 07:27:37 +0200 | |
|---|---|---|
| committer | 2022-08-13 07:27:37 +0200 | |
| commit | 62132ecc8d032ef251d6b54177414a9ba29e8610 (patch) | |
| tree | d16f27f85c4dea8c36c70b7125b14b32032ce5ae /bootstrap | |
| parent | 58af6dcf569c7f83b317d30f8dd85d96d314d785 (diff) | |
fix cgen cond
Diffstat (limited to 'bootstrap')
| -rw-r--r-- | bootstrap/cgen.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/bootstrap/cgen.c b/bootstrap/cgen.c index baf8999..b164905 100644 --- a/bootstrap/cgen.c +++ b/bootstrap/cgen.c @@ -215,7 +215,7 @@ genexpr(struct expr *ex) { pri("(%e %c %e)", ex->binop.lhs, ex->binop.op, ex->binop.rhs); break; case Econd: - pri("(%e) ? (%e) : (%e)", ex->cond.test, ex->cond.t, ex->cond.f); + pri("((%e) ? (%e) : (%e))", ex->cond.test, ex->cond.t, ex->cond.f); break; case Ecall: pri("%e(", ex->call.callee); |