diff --git a/src/uxn.c b/src/uxn.c index 5356d78..3de7530 100644 --- a/src/uxn.c +++ b/src/uxn.c @@ -30,8 +30,8 @@ WITH REGARD TO THIS SOFTWARE. #define INC(s) uxn.s.dat[uxn.s.ptr++] #define DEC(s) uxn.s.dat[--uxn.s.ptr] #define POx(o) if(_2) { PO2(o) } else PO1(o) -#define PO1(o) if(_r) o = DEC(rst); else o = DEC(wst); -#define PO2(o) if(_r) o = DEC(rst) | (DEC(rst) << 8); else o = DEC(wst) | (DEC(wst) << 8); +#define PO1(o) o = _r ? DEC(rst) : DEC(wst); +#define PO2(o) PO1(o) o |= (_r ? DEC(rst) : DEC(wst)) << 8; #define PUx(i) if(_2) { c = (i); PU1(c >> 8) PU1(c) } else PU1(i) #define PU1(i) if(_r) INC(rst) = i; else INC(wst) = i; #define RP1(i) if(_r) INC(wst) = i; else INC(rst) = i; diff --git a/src/uxn11.c b/src/uxn11.c index df2f331..d50f0d7 100644 --- a/src/uxn11.c +++ b/src/uxn11.c @@ -266,7 +266,7 @@ main(int argc, char **argv) int i = 1; char *rom; if(i != argc && argv[i][0] == '-' && argv[i][1] == 'v') { - fprintf(stdout, "Uxn11 - Varvara Emulator, 18 Aug 2024.\n"); + fprintf(stdout, "Uxn11 - Varvara Emulator, 22 Aug 2024.\n"); exit(0); } rom = i == argc ? "boot.rom" : argv[i++]; diff --git a/src/uxncli.c b/src/uxncli.c index 86b34b4..0b5f5c0 100644 --- a/src/uxncli.c +++ b/src/uxncli.c @@ -68,7 +68,7 @@ main(int argc, char **argv) int i = 1; char *rom; if(i != argc && argv[i][0] == '-' && argv[i][1] == 'v') { - fprintf(stdout, "Uxncli - Console Varvara Emulator, 18 Aug 2024.\n"); + fprintf(stdout, "Uxncli - Console Varvara Emulator, 22 Aug 2024.\n"); exit(0); } rom = i == argc ? "boot.rom" : argv[i++];