-- The Optional String Word Set
Copyright (C) Tektronix, Inc. 1998 - 2001. All rights reserved.
description: The basic words for handling string buffers. There are much more buffer words used in most Forth implementations around but they can usually implemented as colon-word quite effectivly on the basis of the STRING wordset.
check the given buffer if it contains whitespace at its end. If so, shorten str-len to meet the last non-whitespace character in the buffer.
dpANS 17.6.1.0170 - standard forth word
shorten the buffer from the beginning by n characters, i.e.
str-ptr += n ; str-len -= n;
dpANS 17.6.1.0245 - standard forth word
( str-ptr str-len -- )(
dpANS 17.6.1.0780 - standard forth word
memcpy an area from->to for len bytes, starting at the lower addresses, see CMOVE>
dpANS 17.6.1.0910 - standard forth word
memcpy an area from->to for len bytes, starting with the higher addresses, see CMOVE
compare both str-buffers, return 0 if they are equal, -1 if lower or shorter, and 1 if greater or longer
dpANS 17.6.1.0935 - standard forth word
search the str-buffer1 for the text of str-buffer2, if it is contained return TRUE and return buffer-values that point to the contained string, otherwise return FALSE and leave the original str-buffer1.
dpANS 188.8.131.521 - standard forth word
( -- string )(
compile-time: ( CS: str-ptr str-len -- )
this word does almost the same as LITERAL - it takes an S" string as specified in the CS-STACK at compile time and compiles into the current definition where it is returned as if there were a direct string-literal. This can be used to compute a string-literal at compile-time and hardwire it.
example: : ORIGINAL-HOME [ $HOME COUNT ] SLITERAL ; ( -- str-ptr str-len )
dpANS 184.108.40.2062 - standard forth word
( .. )(
( 1994 ) constant STRING-EXT
an ordinary constant (no special usage info)