Skip to content

Commit 0b9ad3a

Browse files
committed
improve uxn sign extension code (thanks d_m)
1 parent 33a52e9 commit 0b9ad3a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

source/backends/uxn.d

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -284,7 +284,7 @@ class BackendUXN : CompilerBackend {
284284
}
285285

286286
if ((size == 1) && var.type.isSigned) {
287-
output ~= "LIT2r 00ff DUP #80 AND ?{ SWPr } STHr POPr SWP\n";
287+
output ~= "DUP #7f GTH #ff MUL SWP\n";
288288
}
289289
else if (size == 1) {
290290
output ~= "#00 SWP\n";

0 commit comments

Comments
 (0)