diff options
author | Marvin Borner | 2023-04-14 18:02:02 +0200 |
---|---|---|
committer | Marvin Borner | 2023-04-14 18:02:02 +0200 |
commit | 35702ebb4997f5f1aec25ba1c9ba257f352ea493 (patch) | |
tree | e3dd9e543a3344cba23e48dc6bf903d65bc7e2a3 /src/parse.c | |
parent | 43996255f614ac57deb2fc0666f221853c60b343 (diff) |
pqueue lib and fixes
this makes everything dramatically faster
Diffstat (limited to 'src/parse.c')
-rw-r--r-- | src/parse.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/parse.c b/src/parse.c index ff01bf0..6e08d2e 100644 --- a/src/parse.c +++ b/src/parse.c @@ -127,7 +127,9 @@ static struct term *rec_bloc(struct term *term, struct bloc_parsed *bloc) fprintf(stderr, "invalid entry reference\n"); return 0; } - memcpy(term, bloc->entries[term->u.ref.index], sizeof(*term)); + memcpy(term, + bloc->entries[bloc->length - term->u.ref.index - 1], + sizeof(*term)); break; default: fprintf(stderr, "invalid type %d\n", term->type); |