Looking up and creating words
Factor handbook > The language > Words > Word introspection

Prev:word? ( object -- ? )
Next:Uninterned words


A word is said to be interned if it is a member of the vocabulary named by its vocabulary slot. Otherwise, the word is uninterned.

Words whose names are known at parse time -- that is, most words making up your program -- can be referenced in source code by stating their name. However, the parser itself, and sometimes code you write, will need to look up words dynamically.

Parsing words add definitions to the current vocabulary. When a source file is being parsed, the current vocabulary is initially set to scratchpad. The current vocabulary may be changed with the IN: parsing word (see Parse-time word lookup).
create-word ( name vocab -- word )

create-word-in ( str -- word )

lookup-word ( name vocab -- word )