From db826ab909c437c20c4365d0404ab8b853beb07c Mon Sep 17 00:00:00 2001 From: Andy Wingo Date: Fri, 12 May 2023 10:57:58 +0200 Subject: [PATCH] Fix bug in compilation of rsh/lsh * module/language/cps/compile-bytecode.scm (compile-function): The rsh/lsh patterns would never match. I think these would end up dispatching through emit-text though. --- module/language/cps/compile-bytecode.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/module/language/cps/compile-bytecode.scm b/module/language/cps/compile-bytecode.scm index 53a252444..494bb5a0c 100644 --- a/module/language/cps/compile-bytecode.scm +++ b/module/language/cps/compile-bytecode.scm @@ -238,9 +238,9 @@ (emit-usub/immediate asm (from-sp dst) (from-sp (slot x)) y)) (($ $primcall 'umul/immediate y (x)) (emit-umul/immediate asm (from-sp dst) (from-sp (slot x)) y)) - (($ $primcall 'rsh (x y)) + (($ $primcall 'rsh #f (x y)) (emit-rsh asm (from-sp dst) (from-sp (slot x)) (from-sp (slot y)))) - (($ $primcall 'lsh (x y)) + (($ $primcall 'lsh #f (x y)) (emit-lsh asm (from-sp dst) (from-sp (slot x)) (from-sp (slot y)))) (($ $primcall 'rsh/immediate y (x)) (emit-rsh/immediate asm (from-sp dst) (from-sp (slot x)) y))