This website requires JavaScript.
Explore
Help
Register
Sign In
admin
/
j-lang
Watch
1
Star
0
Fork
0
You've already forked j-lang
Code
Issues
Pull Requests
Actions
Packages
Projects
Releases
Wiki
Activity
Files
da9bb6ca6250bd0bac9ef222387e0fc775c26500
j-lang
/
projects
/
vm_simple.j
2 lines
32 B
Plaintext
Raw
Normal View
History
Unescape
Escape
Complete VM parity with eval and fix operator precedence VM: add string concatenation in OP_ADD, len() built-in, multi-arg print/println, undefined variable detection, and GC via OP_NOP. Parser: fix operator precedence by splitting into parse_expr (+,-) and parse_term (*,/) so 8 + 2 * 4 = 16 instead of 40. Compiler: emit OP_NOP at start of NODE_BLOCK to trigger GC.
2026-02-18 02:26:44 +01:00
x = 8 + 2 * 4
print(x, end="\n")
Reference in New Issue
Copy Permalink