Better values docs
parent
3d8f432856
commit
d6264a32ce
|
@ -2,7 +2,7 @@ USING: help.markup help.syntax ;
|
|||
IN: values
|
||||
|
||||
ARTICLE: "values" "Global values"
|
||||
"Usually, dynamically scoped variables are sufficient for holding data which is not literal. But occasionally, for global information that's calculated just once, it's useful to use the word mechanism instead, and set the word to the appropriate value just once. Values abstract over this concept. To create a new word as a value, use the following syntax:"
|
||||
"Usually, dynamically scoped variables are sufficient for holding data which is not literal. But occasionally, for global information that's calculated just once, it's useful to use the word mechanism instead, and set the word to the appropriate value just once. The " { $vocab-link "values" } " vocabulary implements " { $emphasis "values" } ", which abstract over this concept. To create a new word as a value, use the following syntax:"
|
||||
{ $subsection POSTPONE: VALUE: }
|
||||
"To get the value, just call the word. The following words manipulate values:"
|
||||
{ $subsection get-value }
|
||||
|
@ -10,6 +10,8 @@ ARTICLE: "values" "Global values"
|
|||
{ $subsection POSTPONE: to: }
|
||||
{ $subsection change-value } ;
|
||||
|
||||
ABOUT: "values"
|
||||
|
||||
HELP: VALUE:
|
||||
{ $syntax "VALUE: word" }
|
||||
{ $values { "word" "a word to be created" } }
|
||||
|
|
Loading…
Reference in New Issue