Keep stack between eval
#5500
|
I am implementing a REPL and want to keep local variables between calls to eval. I've looked at mirb and tried to do what it does, but I get a crash, maybe because I'm initiating the call from ruby instead of C, so I guess I call vm exec recursively ? I also looked at eval.c but it's more complex (maybe because it needs to work when called from ruby). Any help appreciated. |
Answered by
matz
Jul 7, 2021
Replies: 3 comments 2 replies
|
Show me the code, please. |
0 replies
Answer selected by
matz
|
|
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Probably you can use
mruby-bindinggem (#5362, #5491).Don't forget to include
mruby-bindinggem when build.