P4_NAME_TO_STRING(3)

NAME
p4_name_to_string - NAME>STRING ( name-token -- str-ptr str-len )

SYNOPSIS

#include <pfe/header-ext.h>

FCode p4_name_to_string(---);

DESCRIPTION

convert a name-token into a string-span, used to detect the name for a word and print it. The word ID. can be defined as

      : ID. NAME&gt;STRING TYPE ;

the implementation of NAME>STRING depends on the header layout that is defined during the configuration of the forth system.

      : NAME&gt;STRING COUNT 31 AND ; ( for fig-like names )
      : NAME&gt;STRING COUNT ;        ( default, name is a simple counted string )
      : NAME&gt;STRING @ ZCOUNT ;     ( name-token is a pointer to a C-level string )
      : NAME&gt;STRING COUNT 31 AND   ( hybrid of fig-like and zero-terminated )
           DUP 31 = IF DROP 1+ ZCOUNT THEN
      ;
      : NAME&gt;STRING HEAD:: COUNT CODE:: PAD PLACE PAD ; ( different i86 segments )

AUTHOR

    • Guido U. Draheim (modified by $Author: guidod $)

COPYRIGHT

Copyright (C) Tektronix, Inc. 1998 - 2001. Copyright (C) 2005 - 2008 Guido U. Draheim <guidod@gmx.de>