~rabbits/uxnlin

0f87eff30b111272e815fcbe4d0dc9c050ab7788 — neauoire 5 months ago cbc31ae
Added new recipes
2 files changed, 18 insertions(+), 2 deletions(-)

M etc/example.tal
M src/uxnlin.tal
M etc/example.tal => etc/example.tal +4 -1
@@ 7,7 7,7 @@
( program )

|0100 ( -> )
	

	( testing: statics )
	#0001 #0003 ADD2



@@ 44,8 44,11 @@
	DUP #00 SWP
	DUP2 #0000 SWP2

	( unstashed )
	#01 STH
	#0001 STH2
	.test STH
	;test STH2

	( literal sequence )
	#12 #12

M src/uxnlin.tal => src/uxnlin.tal +14 -1
@@ 223,7 223,9 @@ JMP2r

	OVR2 OVR2 ;scmp JSR2 ,&pass JCN

	SWP2 LDAk LIT "# NEQ ,&no-lit JCN
	SWP2
	( literals )
	LDAk LIT "# NEQ ,&no-lit JCN
		INC2k LDA LIT "_ NEQ ,&no-lit JCN
			DUP2 ;slen JSR2 #0003 NEQ2 ,&no-byte JCN
				OVR2 ;is-litbyte JSR2 ,&pass JCN


@@ 232,6 234,15 @@ JMP2r
				OVR2 ;is-litshort JSR2 ,&pass JCN
				&no-short
		&no-lit
	( ref byte )
	LDAk LIT ". NEQ ,&no-ref JCN
		INC2k LDA LIT "_ EQU ,&pass JCN
		&no-ref
	( ref short )
	LDAk LIT "; NEQ ,&no-ref2 JCN
		INC2k LDA LIT "_ EQU ,&pass JCN
		&no-ref2

	POP2 POP2 #00

JMP2r


@@ 422,6 433,8 @@ JMP2r
	"AND   $1 "JMP    $1 :unsafe
	"ORA   $1 "JMP    $1 :unsafe
	"EOR   $1 "JMP    $1 :unsafe
	";_    $1 "STH2   $1 :unstashed
	"._    $1 "STH    $1 :unstashed
	"#__   $1 "STH    $1 :unstashed
	"#____ $1 "STH2   $1 :unstashed
	"#__   $1 "#__    $1 :combine