| |
|
| ' input-stream-header IS (header) |
' input-stream-header IS (header) |
| |
|
| \ !! make that a 2variable |
2variable nextname-string |
| create nextname-buffer 32 chars allot |
|
| |
|
| : nextname-header ( -- ) |
: nextname-header ( -- ) |
| nextname-buffer count header, |
nextname-string 2@ header, |
| |
nextname-string free-mem-var |
| input-stream ; |
input-stream ; |
| |
|
| \ the next name is given in the string |
\ the next name is given in the string |
| : nextname ( c-addr u -- ) \ gforth |
: nextname ( c-addr u -- ) \ gforth |
| \g The next defined word will have the name @var{c-addr u}; the |
\g The next defined word will have the name @var{c-addr u}; the |
| \g defining word will leave the input stream alone. |
\g defining word will leave the input stream alone. |
| dup &31 u> -&19 and throw \ !! make buffer variable-sized |
|
| name-too-long? |
name-too-long? |
| nextname-buffer c! ( c-addr ) |
nextname-string free-mem-var |
| nextname-buffer count move |
save-mem nextname-string 2! |
| ['] nextname-header IS (header) ; |
['] nextname-header IS (header) ; |
| |
|
| : noname-header ( -- ) |
: noname-header ( -- ) |