view interps/cfunge/cfunge-src/tests/refc-invalid-deref.b98 @ 11833:e9e97bd215d3 draft

<b_jonas> `` set -e; cd share/mtg; tr -d \\\\r <MagicCompRules_20190612.txt > rules.txt
author HackEso <hackeso@esolangs.org>
date Thu, 13 Jun 2019 21:47:53 +0000
parents 859f9b4339e6
children
line wrap: on
line source

v >0a"CFER oN" >:#,_@            ; This program tests invalid D in REFC ;
>#^"CFER"4(nv
v           <
>1. #v 0D  "DAB" >:#,_  @        ; Derefence 0 ;
     >a"DOOG">:#,_v
v                 <


>2. #v 01-D  "DAB" >:#,_  @      ; Derefence negative ;
     >a"DOOG">:#,_v
v                 <


>3. 45+ #v D  "DAB" >:#,_  @     ; Derefence postive ;
         >a"DOOG">:#,_v
v                     <


>4. #v nD  "DAB" >:#,_  @        ; Derefence on empty stack ;
     >a"DOOG">:#,_v
v                 <

a                                ; That's all ;
,
@