home *** CD-ROM | disk | FTP | other *** search
/ ftp.barnyard.co.uk / 2015.02.ftp.barnyard.co.uk.tar / ftp.barnyard.co.uk / cpm / walnut-creek-CDROM / ENTERPRS / CPM / UTILS / S / ZCNFG21.LBR / CFGLIB.LBR / SKSP.Z80 < prev    next >
Text File  |  1991-10-25  |  512b  |  16 lines

  1.     public    sksp
  2.  
  3. ; Subroutine to skip over spaces in the buffer pointed to by HL.  On return,
  4. ; the zero flag is set if we encountered the end of the line or a command
  5. ; separator character.
  6.  
  7. sksp:
  8.     ld    a,(hl)        ; Get next character
  9.     inc    hl        ; Point to the following character
  10.     cp    ' '        ; Space?
  11.     jr    z,sksp        ; If so, keep skipping
  12.     dec    hl        ; Back up to non-space
  13.     ret            ; ..and ret with char
  14.  
  15.     end
  16.