Commits

catseye  committed e91da6b

Input source is now terminated with vertical tab instead of NUL.

  • Participants
  • Parent commits 73e02ce

Comments (0)

Files changed (9)

+syntax: regexp
+
+eg/.*\.com
+eg/.*\.COM

File bin/null.txt

Binary file removed.

File bin/shelta.bat

 if exist %8.she type %8.she >>s.she
 if exist %9.she type %9.she >>s.she
 if exist %2.she type %2.she >>s.she
-type bin\null.txt >>s.she
+type bin\vtab.txt >>s.she
 
 rem bin\shelta%1.com <s.she
 bin\shelta%1.com <s.she >%2.com

File bin/sheltan.com

Binary file modified.

File bin/sheltas.com

Binary file modified.

File bin/sheltas2.com

Binary file modified.

File bin/vtab.txt

+

File eg/sheltas.she

   ^tokenba getw ^tokenh putw
   [ ]=scanloop
     ^scanc do ^inbyte putb
-    ^inbyte getb zero ^goteof toif
+    ^inbyte getb \11 - zero ^goteof toif
     \33 ^inbyte getb > ^scanloop toif
 
     [ ]=scisloop

File src/shelta86.s

 ; ----- begin scanning token
 
                 call    word ScanChar   ; get char -> al
-                or      al, al
-                jz      EndFile
+                cmp     al, 0bh         ; is it a vertical tab?
+                je      EndFile
                 cmp     al, 32
                 jbe     WhileFile       ; repeat if char is whitespace
 
                 mov     dx, code
                 sub     cx, dx
                 call    word WriteIt
-                
+
                 xor     al, al
 
 GlobalExit:     mov     ah, 4ch         ; exit to DOS
                 int     21h
 
 WriteIt:
-                mov     ah, 40h
-                mov     bx, 1
+                mov     ah, 40h         ; write data to file
+                mov     bx, 1           ; filehandle #1 = stdout
                 int     21h
                 jnc     .OK
                 mov     al, 32