flat assembler
Message board for the users of flat assembler.
  
       
      Index
      > Main > Converting asm program - OR in a db | 
  
| Author | 
  | 
              
| 
                  
                   cod3b453 10 Jul 2014, 21:24 
                  The following will do it but you'd need a struc and macro version to allow labeled/unlabeled strings.     
                  
                Code: struc str [x] { common local .end db x .end: load b byte from .end-1 b = b or 0x80 store byte b at .end-1 } table str 'tes','t'  | 
              |||
                  
  | 
              
| 
                  
                   l_inc 10 Jul 2014, 22:02 
                  MajorDill
 
                  Just use the operator or instead of the pipe character: Code: table db 'LIS', 'T' or 80h _________________ Faith is a superposition of knowledge and fallacy  | 
              |||
                  
  | 
              
| 
                  
                   shutdownall 10 Jul 2014, 23:44 
                  This looks similar to Sinclair's ZX Basic structures.   
                  
                Code: DEFB $31,$34,$26,$29+$80 ; LOAD DEFB $31,$2E,$38,$39+$80 ; LIST DEFB $31,$2A,$39+$80 ; LET DEFB $35,$26,$3A,$38,$2A+$80 ; PAUSE DEFB $33,$2A,$3D,$39+$80 ; NEXT DEFB $35,$34,$30,$2A+$80 ; POKE For use in ASCII I would prefer Code: table: db 'LIS','T'+$80 dw adr_list db 'LOA','D'+$80 dw adr_load  | 
              |||
                  
  | 
              
< Last Thread | Next Thread >  | 
    
Forum Rules: 
  | 
    
Copyright © 1999-2025, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.