i am getting a status code return as 0 locally but -1 on the remote tester as shown on the image.
my github repo link is GitHub - abdelshafei/CodeInterpreter: Custom programming language interpreter
i am getting a status code return as 0 locally but -1 on the remote tester as shown on the image.
my github repo link is GitHub - abdelshafei/CodeInterpreter: Custom programming language interpreter
Thanks for your post! I’ll take a look and get back to you by the end of the week.
I had something similar happen… and I did not understand why it didn’t work until I threw my program at valgrind and then I realized my code read memory that was NOT allocated.
The runner failing with exit code -1 without any feedback is a problem though.
Anyways, those runners are super strict about memory management.
Those are guesses of what would cause your program to exit with code -1:
After changing the content of test.lox to print false;
like the runner did and running your code under valgrind, we can see where the issue comes from:
nvm. was able to fix it by dynamically allocating the vector of statements instead of doing so statically. thanks for the help!
This topic was automatically closed 5 days after the last reply. New replies are no longer allowed.