[#809] Improve interpreter re-iterating on LOOP instr
Description
Problem: Our interpreter does not treat loops and meta instructions in a proper way. Once execution of a loop comes to repeating the loop's body, it just recursively runs on LOOP body
here. But if LOOP
instruction had a source location or meta attached to it, they won't appear on that repetitions
Solution: Add isMetaWrapper
to InterpreterState
which build a wrapper attaching Meta
and WithLoc
along the way. This wrapper the is used when it meets loop instruction.
Related issue(s)
Resolves #809 (closed)
✅ Checklist for your Merge Request
Related changes (conditional)
-
Tests (see short guidelines)
-
If I added new functionality, I added tests covering it. -
If I fixed a bug, I added a regression test to prevent the bug from silently reappearing again.
-
-
Documentation
Stylistic guide (mandatory)
-
My commits comply with the following policy. -
My code complies with the style guide.
Edited by Moremi Vannak