3 ms·
> Nim's VM runs from Nim AST What does this mean? There's a runtime VM or compile time VM?
by mathisfun123 3y ago
> Nim's VM runs from Nim AST
What does this mean? There's a runtime VM or compile time VM?
- elcritch 3y ago> What does this mean? There's a runtime VM or compile time VM? Compile time VM. It's used to run macros / templates / concepts. You can also run most code at compile time in a `static` block except for stuff that needs C calls. You can also compile the VM into a program and use it as a runtime VM (see https://github.com/beef331/nimscripter https://github.com/beef331/nimscripter) which I do in my GUI lib. NIR should enable the compile time VM to run faster too, and possibly use JIT'ed code.
- mathisfun123 3y agoah so like clang's constexpr. got it. thanks