diff options
| author | eunhhu <[email protected]> | 2026-10-19 07:23:29 +0100 |
|---|---|---|
| committer | eunhhu <[email protected]> | 2026-10-19 07:23:29 +0100 |
| commit | 6463228d028a4755ef819dcfbbf6426e3a9f8626 (patch) | |
| tree | 22e88a1c29dcef097611e2fbba4f83b9ee895f60 /compiler | |
| parent | b116cf7b59db6a90b2d5146742bb838144fa831f (diff) | |
| download | aup-6463228d028a4755ef819dcfbbf6426e3a9f8626.tar.gz aup-6463228d028a4755ef819dcfbbf6426e3a9f8626.zip | |
Lists declared together: three names or more made the statements a cycle (each copy took the first's next, the copy before it), so the compiler never ended (found writing linebreak.aup's nine lists as two lines); frictions declares four
Diffstat (limited to 'compiler')
| -rw-r--r-- | compiler/compile.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/compile.c b/compiler/compile.c index 26e7172..f161182 100644 --- a/compiler/compile.c +++ b/compiler/compile.c @@ -1354,7 +1354,7 @@ static Stmt *statement(Compiler *c, unsigned depth) { for (unsigned i = 1; i < s->name_count; ++i) { Stmt *other = allocate(c, sizeof(*other)); *other = *s; - other->names = NULL, other->name_count = 0; + other->names = NULL, other->name_count = 0, other->next = NULL; /* (s's next is the first other by now) */ memcpy(other->name, s->names[i], NAME); last = last->next = other; } |
