ref: 5c1ae4ce2211e3086b84100b5da21cef08dab6a3
parent: efbfeca2921c4c250faadae339374c6294f3939f
author: Rangi <remy.oukaour+rangi42@gmail.com>
date: Wed Feb 17 06:30:57 EST 2021
Shorter quine test cases
--- a/test/asm/quine.asm
+++ b/test/asm/quine.asm
@@ -1,14 +1,13 @@
-R:MACRO
-REPT _NARG
-PRINT STRSUB("\n\"\\ ENRST1ABCDFGHIMOPU_n#()+,:>",\1+1,1)
-SHIFT
-ENDR
-ENDM
N:MACRO
- R \#
-REPT _NARG
-PRINT"\1",STRSUB("\n,",(_NARG>1)+1,1)
+FOR I,_NARG
+SHIFT I
+PRINT STRSUB("\n\"\\ INRT1,ABCDEFGHMOPSUn_(+-:)",\1+1,1)
+SHIFT-I
+ENDR
+REPT _NARG-1
+PRINT"\1,"
SHIFT
ENDR
+PRINT"\1\n"
ENDM
- N 6,29,18,10,12,6,19,0,6,4,20,8,3,22,5,10,6,15,0,20,6,17,5,8,3,7,8,6,7,21,11,25,1,2,23,2,1,2,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,1,28,2,9,27,9,28,9,26,0,7,16,17,14,8,0,4,5,13,6,0,4,5,13,18,0,5,29,18,10,12,6,19,0,3,6,3,2,24,0,6,4,20,8,3,22,5,10,6,15,0,20,6,17,5,8,1,2,9,1,28,7,8,6,7,21,11,25,1,2,23,28,1,28,25,22,5,10,6,15,30,9,26,27,9,28,9,26,0,7,16,17,14,8,0,4,5,13,6,0,4,5,13,18,0,3,5,3
+ N 5,28,18,10,12,6,19,0,15,19,6,3,4,9,24,5,10,6,16,0,21,17,4,15,7,3,4,0,20,6,4,5,7,3,21,7,6,21,22,11,25,1,2,23,2,1,2,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,1,9,2,8,26,8,9,8,29,0,21,17,4,15,7,27,4,0,14,5,13,6,0,6,14,20,7,3,24,5,10,6,16,27,8,0,20,6,4,5,7,1,2,8,9,1,0,21,17,4,15,7,0,14,5,13,6,0,20,6,4,5,7,1,2,8,2,23,1,0,14,5,13,18,0,3,5,3
--- a/test/asm/quine.out
+++ b/test/asm/quine.out
@@ -1,14 +1,13 @@
-R:MACRO
-REPT _NARG
-PRINT STRSUB("\n\"\\ ENRST1ABCDFGHIMOPU_n#()+,:>",\1+1,1)
-SHIFT
-ENDR
-ENDM
N:MACRO
- R \#
-REPT _NARG
-PRINT"\1",STRSUB("\n,",(_NARG>1)+1,1)
+FOR I,_NARG
+SHIFT I
+PRINT STRSUB("\n\"\\ INRT1,ABCDEFGHMOPSUn_(+-:)",\1+1,1)
+SHIFT-I
+ENDR
+REPT _NARG-1
+PRINT"\1,"
SHIFT
ENDR
+PRINT"\1\n"
ENDM
- N 6,29,18,10,12,6,19,0,6,4,20,8,3,22,5,10,6,15,0,20,6,17,5,8,3,7,8,6,7,21,11,25,1,2,23,2,1,2,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,1,28,2,9,27,9,28,9,26,0,7,16,17,14,8,0,4,5,13,6,0,4,5,13,18,0,5,29,18,10,12,6,19,0,3,6,3,2,24,0,6,4,20,8,3,22,5,10,6,15,0,20,6,17,5,8,1,2,9,1,28,7,8,6,7,21,11,25,1,2,23,28,1,28,25,22,5,10,6,15,30,9,26,27,9,28,9,26,0,7,16,17,14,8,0,4,5,13,6,0,4,5,13,18,0,3,5,3
+ N 5,28,18,10,12,6,19,0,15,19,6,3,4,9,24,5,10,6,16,0,21,17,4,15,7,3,4,0,20,6,4,5,7,3,21,7,6,21,22,11,25,1,2,23,2,1,2,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,1,9,2,8,26,8,9,8,29,0,21,17,4,15,7,27,4,0,14,5,13,6,0,6,14,20,7,3,24,5,10,6,16,27,8,0,20,6,4,5,7,1,2,8,9,1,0,21,17,4,15,7,0,14,5,13,6,0,20,6,4,5,7,1,2,8,2,23,1,0,14,5,13,18,0,3,5,3
--- a/test/asm/quine2.asm
+++ b/test/asm/quine2.asm
@@ -1,4 +1,4 @@
-q: macro
- println \1,"\1"
+q:macro
+println\1,"\1"
endm
- q "q: macro\n\tprintln \\1,\"\\1\"\nendm\n\tq "
+ q"q:macro\nprintln\\1,\"\\1\"\nendm\n q"
--- a/test/asm/quine2.out
+++ b/test/asm/quine2.out
@@ -1,4 +1,4 @@
-q: macro
- println \1,"\1"
+q:macro
+println\1,"\1"
endm
- q "q: macro\n\tprintln \\1,\"\\1\"\nendm\n\tq "
+ q"q:macro\nprintln\\1,\"\\1\"\nendm\n q"