Documentation updates

db4
Slava Pestov 2009-04-14 17:55:58 -05:00
parent f850ba5665
commit 128715def4
4 changed files with 17 additions and 3 deletions

View File

@ -253,12 +253,12 @@ ARTICLE: "handbook-language-reference" "Language reference"
{ $subsection "conventions" }
{ $subsection "syntax" }
{ $subsection "effects" }
{ $subsection "evaluator" }
"Data types:"
{ $subsection "booleans" }
{ $subsection "numbers" }
{ $subsection "collections" }
"Evaluation semantics:"
{ $subsection "evaluator" }
"Evaluation:"
{ $subsection "words" }
{ $subsection "shuffle-words" }
{ $subsection "combinators" }

View File

@ -24,6 +24,7 @@ ARTICLE: "wrappers" "Wrappers"
"Wrappers are used to push words on the data stack; they evaluate to the object being wrapped:"
{ $subsection wrapper }
{ $subsection literalize }
"Wrapper literal syntax is documented in " { $link "syntax-words" } "."
{ $see-also "combinators" } ;
ABOUT: "quotations"

View File

@ -0,0 +1,12 @@
USING: help.markup help.syntax words.constant ;
IN: words.constant
ARTICLE: "words.constant" "Constants"
"There is a syntax for defining words which push literals on the stack."
$nl
"Define a new word that pushes a literal on the stack:"
{ $subsection POSTPONE: CONSTANT: }
"Define an constant at run-time:"
{ $subsection define-constant } ;
ABOUT: "words.constant"

View File

@ -31,7 +31,7 @@ $nl
{ $subsection define }
{ $subsection define-declared }
{ $subsection define-inline }
"Word definitions should declare their stack effect, unless the definition is completely trivial. See " { $link "effect-declaration" } "."
"Word definitions must declare their stack effect. See " { $link "effect-declaration" } "."
$nl
"All other types of word definitions, such as " { $link "words.symbol" } " and " { $link "generic" } ", are just special cases of the above." ;
@ -75,6 +75,7 @@ ARTICLE: "word-definition" "Defining words"
{ $subsection "colon-definition" }
{ $subsection "words.symbol" }
{ $subsection "words.alias" }
{ $subsection "words.constant" }
{ $subsection "primitives" }
{ $subsection "deferred" }
{ $subsection "declarations" }