public
/
ack.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e13ff5b
)
Oops --- hadn't updated the nts array for the new child order.
author
David Given
<dg@cowlark.com>
Tue, 4 Oct 2016 19:32:28 +0000
(21:32 +0200)
committer
David Given
<dg@cowlark.com>
Tue, 4 Oct 2016 19:32:28 +0000
(21:32 +0200)
util/mcgg/iburg.c
patch
|
blob
|
history
diff --git
a/util/mcgg/iburg.c
b/util/mcgg/iburg.c
index
af3106a
..
3eb703b
100644
(file)
--- a/
util/mcgg/iburg.c
+++ b/
util/mcgg/iburg.c
@@
-779,9
+779,12
@@
static char* computents(Tree t, char* bp)
if (t)
{
Nonterm p = t->op;
- if (
p->kind == NONTERM
)
+ if (
!t->left && !t->right
)
{
- sprintf(bp, "%s_%s_NT, ", prefix, p->name);
+ if (p->kind == NONTERM)
+ sprintf(bp, "%s_%s_NT, ", prefix, p->name);
+ else
+ sprintf(bp, "0, ");
bp += strlen(bp);
}
else