Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Dynamic Eval

eval@sys lets you execute lil code from a string at runtime:

include sys

eval@sys("x = 42")
write(x)

You can capture the return value:

include sys
result = eval@sys("1 + 2")
write(result)

Eval uses the same parser and interpreter as normal execution. Variables set inside eval are visible to the caller afterwards.

Errors during eval are caught silently and return 0.