scc

simple c99 compiler
git clone git://git.simple-cc.org/scc
Log | Files | Refs | README | LICENSE

commit 42eaab3f622a05d33a00df47774bc46377465744
parent e062187973bf14214d5917be3ec9b70fa0f68d9f
Author: Roberto E. Vargas Caballero <k0ga@shike2.com>
Date:   Thu, 15 Sep 2016 16:46:50 +0200

[cc2] Forces the value of op in constnode()

The value was set only in allocated nodes, but in nodes
passed as parameters it was not set.

Diffstat:
Mcc2/code.c | 1+
1 file changed, 1 insertion(+), 0 deletions(-)

diff --git a/cc2/code.c b/cc2/code.c @@ -85,6 +85,7 @@ constnode(Node *np, TUINT n, Type *tp) { if (!np) np = newnode(OCONST); + np->op = OCONST; np->left = NULL; np->right = NULL; np->type = *tp;