aboutsummaryrefslogtreecommitdiffstats
path: root/csc
diff options
context:
space:
mode:
authorRose Hogenson <rhogenson@posteo.net>2022-07-29 22:41:17 -0700
committerRose Hogenson <rhogenson@posteo.net>2022-07-29 22:41:17 -0700
commitc7ff0b98146693b60a3f075818f96764f646b2d5 (patch)
treeb8d2f409a934ae8c3858a30f42d1799b8abee5da /csc
parent762431b0f0a6ead18a93a05c0f3269dca5b8fef1 (diff)
downloadchromatopelma-c7ff0b98146693b60a3f075818f96764f646b2d5.tar.zst
Fix the bytecode interpreter.
I'm too scared to actually try to run it right now.
Diffstat (limited to 'csc')
-rw-r--r--csc/encoding.csc4
1 files changed, 4 insertions, 0 deletions
diff --git a/csc/encoding.csc b/csc/encoding.csc
index f6a003d..1208993 100644
--- a/csc/encoding.csc
+++ b/csc/encoding.csc
@@ -167,6 +167,10 @@
(('exit code)
(make-opcode w 13 (is-const? code) #f)
(arg->le-bytes w code))
+ (('alloc-bytevector dest size)
+ (make-opcode w 14 (is-const? size) #f)
+ (arg->le-bytes w dest)
+ (arg->le-bytes w size))
(_ (error "invalid opcode" opcode))))