Skip to content

Commit

Permalink
Merge #68
Browse files Browse the repository at this point in the history
68: Fix location set on proto loading. r=ptersilie a=Pavel-Durov

Related: #62

+ Identifying loop instructions using proto code instead of loop index.

Co-authored-by: Pavel Durov <[email protected]>
  • Loading branch information
bors[bot] and Pavel-Durov authored Sep 18, 2023
2 parents 069c0b9 + f670938 commit 950a7ab
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/lyk.c
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ inline void yk_on_proto_loaded(Proto *f) {
lua_assert(f->yklocs != NULL && "Expected yklocs to be defined!");
f->yklocs_size = f->sizecode;
for (int i = 0; i < f->sizecode; i++) {
if (is_loop_start(i)) {
if (is_loop_start(f->code[i])) {
set_location(f, i);
}
}
Expand Down

0 comments on commit 950a7ab

Please sign in to comment.