From 6e635d94a3d65d3e73c362f22b3842e800653f8f Mon Sep 17 00:00:00 2001 From: d_m Date: Thu, 5 Sep 2024 10:11:43 -0400 Subject: [PATCH] Fix stack imbalance --- gui/m291/src/m291.tal | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/gui/m291/src/m291.tal b/gui/m291/src/m291.tal index dd9a06f..99a1e1a 100644 --- a/gui/m291/src/m291.tal +++ b/gui/m291/src/m291.tal @@ -458,17 +458,17 @@ @min ( x^ y^ -- min^ ) LTHk JMP SWP POP JMP2r -@common-folder-prefix ( -- ) - .lines/folders LDZ ?{ JMP2r } +@common-folder-prefix ( -- len^ ) + .lines/folders LDZ ?{ #00 JMP2r } ;mem/folders DUP2 LIT2 [ 00 -lines/folders ] LDZ #70 SFT2 ADD2 !common-prefix-0 -@common-track-prefix ( -- ) - .lines/tracks LDZ ?{ JMP2r } +@common-track-prefix ( -- len^ ) + .lines/tracks LDZ ?{ #00 JMP2r } ;mem/tracks DUP2 LIT2 [ 00 -lines/tracks ] LDZ #70 SFT2 ADD2 ( >> ) -@common-prefix-0 ( first* limit* -- ) +@common-prefix-0 ( first* limit* -- len^ ) SWP2 DUP2k str-len STH ( limit* first* first* [len^] ) ,&s0 STR2 #0080 ADD2 ( limit* first+128* [len^] ) &loop GTH2k ?&ok POP2 POP2 STHr JMP2r ( len^ )