Benutzer-Werkzeuge

Webseiten-Werkzeuge


words:skip
: skip  ( addr len c -- addr' len' )
    \ Within the string given by ADDR and LEN skip leading occurances of
    \ character C. Return the remaining string denoted by ADDR' and LEN'.
    >R
    BEGIN ( addr len )
      DUP 
    WHILE ( addr len )  
      OVER C@ R@ =  
    WHILE  
      1 /STRING
    REPEAT THEN 
    R> DROP ; 

Tags: ANS-Forth string outer-interpreter WORD

words/skip.txt · Zuletzt geändert: 2010-12-29 18:12 von 127.0.0.1