]> gitweb.factorcode.org Git - factor.git/commitdiff
improve help by linking to types directly.
authorJohn Benediktsson <mrjbq7@gmail.com>
Sat, 24 May 2014 03:20:15 +0000 (20:20 -0700)
committerJohn Benediktsson <mrjbq7@gmail.com>
Sat, 24 May 2014 03:20:15 +0000 (20:20 -0700)
123 files changed:
basis/ascii/ascii-docs.factor
basis/binary-search/binary-search-docs.factor
basis/bit-arrays/bit-arrays-docs.factor
basis/bit-vectors/bit-vectors-docs.factor
basis/boxes/boxes-docs.factor
basis/calendar/calendar-docs.factor
basis/channels/channels-docs.factor
basis/channels/remote/remote-docs.factor
basis/cocoa/apple-script/apple-script-docs.factor
basis/cocoa/nibs/nibs-docs.factor
basis/cocoa/pasteboard/pasteboard-docs.factor
basis/compiler/tree/propagation/known-words/known-words-docs.factor
basis/concurrency/mailboxes/mailboxes-docs.factor
basis/concurrency/promises/promises-docs.factor
basis/cpu/architecture/architecture-docs.factor
basis/csv/csv-docs.factor
basis/db/db-docs.factor
basis/db/types/types-docs.factor
basis/debugger/debugger-docs.factor
basis/deques/deques-docs.factor
basis/disjoint-sets/disjoint-sets-docs.factor
basis/dlists/dlists-docs.factor
basis/documents/documents-docs.factor
basis/furnace/auth/auth-docs.factor
basis/furnace/auth/features/deactivate-user/deactivate-user-docs.factor
basis/furnace/auth/features/edit-profile/edit-profile-docs.factor
basis/furnace/auth/features/recover-password/recover-password-docs.factor
basis/furnace/auth/features/registration/registration-docs.factor
basis/furnace/utilities/utilities-docs.factor
basis/game/input/input-docs.factor
basis/grouping/grouping-docs.factor
basis/heaps/heaps-docs.factor
basis/help/help-docs.factor
basis/help/help.factor
basis/help/topics/topics-docs.factor
basis/html/forms/forms-docs.factor
basis/http/server/server-docs.factor
basis/interval-maps/interval-maps-docs.factor
basis/inverse/inverse-docs.factor
basis/io/buffers/buffers-docs.factor
basis/io/files/info/info-docs.factor
basis/io/files/info/unix/unix-docs.factor
basis/io/files/unique/unique-docs.factor
basis/io/monitors/monitors-docs.factor
basis/io/ports/ports-docs.factor
basis/io/styles/styles-docs.factor
basis/json/writer/writer-docs.factor
basis/lcs/lcs-docs.factor
basis/lists/lazy/lazy-docs.factor
basis/lists/lists-docs.factor
basis/math/bitwise/bitwise-docs.factor
basis/math/functions/functions-docs.factor
basis/math/intervals/intervals-docs.factor
basis/math/polynomials/polynomials-docs.factor
basis/math/primes/lucas-lehmer/lucas-lehmer-docs.factor
basis/math/primes/miller-rabin/miller-rabin-docs.factor
basis/math/primes/primes-docs.factor
basis/math/primes/safe/safe-docs.factor
basis/math/rectangles/rectangles-docs.factor
basis/math/vectors/vectors-docs.factor
basis/opengl/capabilities/capabilities-docs.factor
basis/opengl/framebuffers/framebuffers-docs.factor
basis/opengl/shaders/shaders-docs.factor
basis/peg/ebnf/ebnf-docs.factor
basis/peg/parsers/parsers-docs.factor
basis/peg/peg-docs.factor
basis/peg/search/search-docs.factor
basis/persistent/heaps/heaps-docs.factor
basis/porter-stemmer/porter-stemmer-docs.factor
basis/prettyprint/backend/backend-docs.factor
basis/prettyprint/prettyprint-docs.factor
basis/prettyprint/sections/sections-docs.factor
basis/prettyprint/stylesheet/stylesheet-docs.factor
basis/random/random-docs.factor
basis/regexp/regexp-docs.factor
basis/see/see-docs.factor
basis/sequences/deep/deep-docs.factor
basis/stack-checker/stack-checker-docs.factor
basis/tools/annotations/annotations-docs.factor
basis/tools/crossref/crossref-docs.factor
basis/ui/clipboards/clipboards-docs.factor
basis/ui/gadgets/gadgets-docs.factor
basis/ui/gadgets/glass/glass-docs.factor
basis/ui/gadgets/sliders/sliders-docs.factor
basis/ui/gestures/gestures-docs.factor
basis/ui/operations/operations-docs.factor
basis/ui/ui-docs.factor
basis/unicode/case/case-docs.factor
basis/unicode/data/data-docs.factor
basis/urls/encoding/encoding-docs.factor
basis/urls/urls-docs.factor
basis/validators/validators-docs.factor
basis/vocabs/refresh/refresh-docs.factor
basis/xml-rpc/xml-rpc-docs.factor
basis/xml/data/data-docs.factor
basis/xml/traversal/traversal-docs.factor
basis/xml/writer/writer-docs.factor
core/alien/alien-docs.factor
core/classes/algebra/algebra-docs.factor
core/classes/classes-docs.factor
core/classes/tuple/tuple-docs.factor
core/combinators/combinators-docs.factor
core/compiler/units/units-docs.factor
core/continuations/continuations-docs.factor
core/destructors/destructors-docs.factor
core/effects/effects-docs.factor
core/generic/standard/standard-docs.factor
core/hashtables/hashtables-docs.factor
core/io/files/files-docs.factor
core/io/pathnames/pathnames-docs.factor
core/kernel/kernel-docs.factor
core/lexer/lexer-docs.factor
core/math/floats/floats-docs.factor
core/math/integers/integers-docs.factor
core/math/math-docs.factor
core/math/order/order-docs.factor
core/parser/parser-docs.factor
core/sequences/sequences-docs.factor
core/sets/sets-docs.factor
core/splitting/splitting-docs.factor
core/syntax/syntax-docs.factor
core/system/system-docs.factor
core/words/words-docs.factor

index ba94b1123897aa8f3bed3b63b23688426a0e2007..924246071879507f4453ddbb819af210dc0c054c 100644 (file)
@@ -1,44 +1,44 @@
-USING: help.markup help.syntax ;\r
+USING: help.markup help.syntax kernel strings ;\r
 IN: ascii\r
 \r
 HELP: blank?\r
-{ $values { "ch" "a character" } { "?" "a boolean" } }\r
+{ $values { "ch" "a character" } { "?" boolean } }\r
 { $description "Tests for an ASCII whitespace character." } ;\r
 \r
 HELP: letter?\r
-{ $values { "ch" "a character" } { "?" "a boolean" } }\r
+{ $values { "ch" "a character" } { "?" boolean } }\r
 { $description "Tests for a lowercase alphabet ASCII character." } ;\r
 \r
 HELP: LETTER?\r
-{ $values { "ch" "a character" } { "?" "a boolean" } }\r
+{ $values { "ch" "a character" } { "?" boolean } }\r
 { $description "Tests for a uppercase alphabet ASCII character." } ;\r
 \r
 HELP: digit?\r
-{ $values { "ch" "a character" } { "?" "a boolean" } }\r
+{ $values { "ch" "a character" } { "?" boolean } }\r
 { $description "Tests for an ASCII decimal digit character." } ;\r
 \r
 HELP: Letter?\r
-{ $values { "ch" "a character" } { "?" "a boolean" } }\r
+{ $values { "ch" "a character" } { "?" boolean } }\r
 { $description "Tests for an ASCII alphabet character, both upper and lower case." } ;\r
 \r
 HELP: alpha?\r
-{ $values { "ch" "a character" } { "?" "a boolean" } }\r
+{ $values { "ch" "a character" } { "?" boolean } }\r
 { $description "Tests for an alphanumeric ASCII character." } ;\r
 \r
 HELP: printable?\r
-{ $values { "ch" "a character" } { "?" "a boolean" } }\r
+{ $values { "ch" "a character" } { "?" boolean } }\r
 { $description "Tests for a printable ASCII character." } ;\r
 \r
 HELP: control?\r
-{ $values { "ch" "a character" } { "?" "a boolean" } }\r
+{ $values { "ch" "a character" } { "?" boolean } }\r
 { $description "Tests for an ASCII control character." } ;\r
 \r
 HELP: quotable?\r
-{ $values { "ch" "a character" } { "?" "a boolean" } }\r
+{ $values { "ch" "a character" } { "?" boolean } }\r
 { $description "Tests for characters which may appear in a Factor string literal without escaping." } ;\r
 \r
 HELP: ascii?\r
-{ $values { "ch" "a character" } { "?" "a boolean" } }\r
+{ $values { "ch" "a character" } { "?" boolean } }\r
 { $description "Tests for whether a number is an ASCII character." } ;\r
 \r
 HELP: ch>lower\r
@@ -50,23 +50,23 @@ HELP: ch>upper
 { $description "Converts an ASCII character to upper case." } ;\r
 \r
 HELP: >lower\r
-{ $values { "str" "a string" } { "lower" "a string" } }\r
+{ $values { "str" string } { "lower" string } }\r
 { $description "Converts an ASCII string to lower case." } ;\r
 \r
 HELP: >upper\r
-{ $values { "str" "a string" } { "upper" "a string" } }\r
+{ $values { "str" string } { "upper" string } }\r
 { $description "Converts an ASCII string to upper case." } ;\r
 \r
 HELP: >title\r
-{ $values { "str" "a string" } { "title" "a string" } }\r
+{ $values { "str" string } { "title" string } }\r
 { $description "Converts a string to title case." } ;\r
 \r
 HELP: >words\r
-{ $values { "str" "a string" } { "words" "an array of slices" } }\r
+{ $values { "str" string } { "words" "an array of slices" } }\r
 { $description "Divides the string up into words." } ;\r
 \r
 HELP: capitalize\r
-{ $values { "str" "a string" } { "str'" "a string" } }\r
+{ $values { "str" string } { "str'" string } }\r
 { $description "Capitalize all the words in a string." } ;\r
 \r
 ARTICLE: "ascii" "ASCII"\r
index b6a1f48a95925dc5c2e8d720350d6cca01a0f823..289435c5b3782995c1a4f6353e32fd236cf57d86 100644 (file)
@@ -34,13 +34,13 @@ HELP: sorted-index
 { index index-from last-index last-index-from sorted-index } related-words
 
 HELP: sorted-member?
-{ $values { "obj" object } { "seq" "a sorted sequence" } { "?" "a boolean" } }
+{ $values { "obj" object } { "seq" "a sorted sequence" } { "?" boolean } }
 { $description "Tests if the sorted sequence contains " { $snippet "elt" } ". Equality is tested with " { $link = } "." } ;
 
 { member? sorted-member? } related-words
 
 HELP: sorted-member-eq?
-{ $values { "obj" object } { "seq" "a sorted sequence" } { "?" "a boolean" } }
+{ $values { "obj" object } { "seq" "a sorted sequence" } { "?" boolean } }
 { $description "Tests if the sorted sequence contains " { $snippet "elt" } ". Equality is tested with " { $link eq? } "." } ;
 
 { member-eq? sorted-member-eq? } related-words
index df81771ae0753e84be6f68a613a5dc49367cbe72..899cfebcafb1afc0b95dd36dedce460a0f38c299 100644 (file)
@@ -1,5 +1,4 @@
-USING: arrays help.markup help.syntax kernel
-kernel.private math prettyprint strings vectors sbufs ;
+USING: help.markup help.syntax math sequences ;
 IN: bit-arrays
 
 ARTICLE: "bit-arrays" "Bit arrays"
@@ -48,7 +47,7 @@ HELP: <bit-array>
 { $description "Creates a new bit array with the given length and all elements initially set to " { $link f } "." } ;
 
 HELP: >bit-array
-{ $values { "seq" "a sequence" } { "bit-array" bit-array } }
+{ $values { "seq" sequence } { "bit-array" bit-array } }
 { $description "Outputs a freshly-allocated bit array whose elements have the same boolean values as a given sequence." } ;
 
 HELP: clear-bits
index f8d5644cf21a555876d54ea6befa86d6f095e259..34bc8f5ab3355649163c7a005d51785e6da9b88f 100644 (file)
@@ -1,5 +1,4 @@
-USING: arrays bit-arrays help.markup help.syntax kernel\r
-combinators ;\r
+USING: help.markup help.syntax sequences ;\r
 IN: bit-vectors\r
 \r
 ARTICLE: "bit-vectors" "Bit vectors"\r
@@ -30,7 +29,7 @@ HELP: <bit-vector>
 { $description "Creates a new bit vector that can hold " { $snippet "n" } " bits before resizing." } ;\r
 \r
 HELP: >bit-vector\r
-{ $values { "seq" "a sequence" } { "vector" bit-vector } }\r
+{ $values { "seq" sequence } { "vector" bit-vector } }\r
 { $description "Outputs a freshly-allocated bit vector with the same elements as a given sequence." } ;\r
 \r
 HELP: ?V{\r
index 7b286829103c6c4fd0350bc5c10eef85990acb0a..5c0514b2132e49f6b4574d719cdd7f2c6b350ee4 100644 (file)
@@ -19,7 +19,7 @@ HELP: box>
 { $errors "Throws an error if the box is empty." } ;\r
 \r
 HELP: ?box\r
-{ $values { "box" box } { "value/f" "the value of the box or " { $link f } } { "?" "a boolean" } }\r
+{ $values { "box" box } { "value/f" "the value of the box or " { $link f } } { "?" boolean } }\r
 { $description "If the box is full, removes the value from the box and pushes " { $link t } ". If the box is empty pushes " { $snippet "f f" } "." } ;\r
 \r
 ARTICLE: "boxes" "Boxes"\r
index 6442c232a313fd64118b57c693675f5faa09ac1c..b2e42958ef74fe455b0a5edb536e1516eec323b1 100644 (file)
@@ -175,7 +175,7 @@ HELP: nanoseconds
 { years months days hours minutes seconds milliseconds microseconds nanoseconds } related-words
 
 HELP: leap-year?
-{ $values { "obj" object } { "?" "a boolean" } }
+{ $values { "obj" object } { "?" boolean } }
 { $description "Returns " { $link t } " if the object represents a leap year." }
 { $examples
     { $example "USING: calendar prettyprint ;"
@@ -357,7 +357,7 @@ HELP: <zero>
 { $description "Returns a zero timestamp that consists of zeros for every slot. Used to see if timestamps are valid." } ;
 
 HELP: valid-timestamp?
-{ $values { "timestamp" timestamp } { "?" "a boolean" } }
+{ $values { "timestamp" timestamp } { "?" boolean } }
 { $description "Tests if a timestamp is valid or not." } ;
 
 HELP: unix-1970
index 09dac901fe75efb16f95dfca46abcd9826531d1e..931d4241954e0ec8f830528dc5f63fc486f79e79 100644 (file)
@@ -1,10 +1,10 @@
 ! Copyright (C) 2007 Chris Double.
 ! See http://factorcode.org/license.txt for BSD license.
-USING: help.syntax help.markup ;
+USING: help.syntax help.markup kernel ;
 IN: channels
 
 HELP: <channel>
-{ $values { "channel" "a channel object" } 
+{ $values { "channel" channel }
 }
 { $description "Create a channel that can be used for communicating between "
 "concurrent processes and threads. " { $link to } " and " { $link from }
@@ -15,19 +15,19 @@ HELP: <channel>
 { $see-also from to } ;
 
 HELP: to
-{ $values { "value" "an object" } 
-          { "channel" "a channel object" } 
+{ $values { "value" object }
+          { "channel" channel }
 }
 { $description "Sends an object to a channel. The send operation is synchronous."
 " It will block the calling thread until there is a receiver waiting "
 "for data on the channel. It will return when the receiver has received "
-"the data successfully." 
+"the data successfully."
 }
 { $see-also <channel> from } ;
 
 HELP: from
-{ $values  { "channel" "a channel object" } 
-           { "value" "an object" }
+{ $values  { "channel" channel }
+           { "value" object }
 }
 { $description "Receives an object from a channel. The operation is synchronous."
 " It will block the calling thread until there is data in the channel." 
index 2215d959a30060109f4849a6ab6593a2b1ae0bba..bbecb361ea077e62aa694a008dc8f1dca5199bed 100644 (file)
@@ -1,7 +1,7 @@
 ! Copyright (C) 2007 Chris Double.
 ! See http://factorcode.org/license.txt for BSD license.
 USING: channels concurrency.distributed help.markup help.syntax
-io.servers ;
+io.servers strings ;
 IN: channels.remote
 
 HELP: <remote-channel>
@@ -20,7 +20,7 @@ HELP: <remote-channel>
 { $see-also publish unpublish } ;
 
 HELP: unpublish
-{ $values { "id" "a string" }
+{ $values { "id" string }
 }
 { $description "Stop a previously published channel from being "
 "accessible by remote nodes."
@@ -32,7 +32,7 @@ HELP: unpublish
 
 HELP: publish
 { $values { "channel" "a channel object" }
-          { "id" "a string" }
+          { "id" string }
 }
 { $description "Make a channel accessible via remote Factor nodes. "
 "An id is returned that can be used by another node to use " 
index 2a2de9095c66f8715b41d384180b9eef764f495f..8013bd2f9f6baf37f0a5da6b7299f797be417e51 100644 (file)
@@ -9,5 +9,5 @@ HELP: run-apple-script
 
 HELP: APPLESCRIPT:
 { $syntax "APPLESCRIPT: word ...applescript... ;APPLESCRIPT" }
-{ $values { "word" "a word" } { "...applescript..." "AppleScript source text" } }
+{ $values { "word" "a new word to define" } { "...applescript..." "AppleScript source text" } }
 { $description "Defines a word that when called will run the provided uncompiled AppleScript.  The word has stack effect " { $snippet "( -- )" } " due to return values being currently unsupported." } ;
index ff53cb0b5847b4fbe43374863b9cbf0f4b7b4b7f..b1c3f2a04e7f907df5d056062f35b1d4292bd435 100644 (file)
@@ -1,4 +1,4 @@
-USING: help.markup help.syntax strings ;
+USING: help.markup help.syntax sequences strings ;
 IN: cocoa.nibs
 
 HELP: load-nib
@@ -11,6 +11,6 @@ HELP: nib-named
 { $see-also nib-objects } ;
 
 HELP: nib-objects
-{ $values { "anNSNib" "an instance of NSNib" } { "objects/f" "a sequence" } }
+{ $values { "anNSNib" "an instance of NSNib" } { "objects/f" { $maybe sequence } } }
 { $description "Instantiates the top-level objects of the " { $snippet ".nib" } " file loaded by anNSNib.  First create an NSNib instance using " { $link nib-named } "." } 
-{ $see-also nib-named } ;
\ No newline at end of file
+{ $see-also nib-named } ;
index f63bc0ec472b28d9a9b37f0604a2f9b71e46dcb3..e6af5ab6b603d9a957029405521158f4093394a2 100644 (file)
@@ -1,8 +1,8 @@
-USING: help.markup help.syntax strings ;
+USING: help.markup help.syntax kernel strings ;
 IN: cocoa.pasteboard
 
 HELP: pasteboard-string?
-{ $values { "pasteboard" "an " { $snippet "NSPasteBoard" } } { "?" "a boolean" } }
+{ $values { "pasteboard" "an " { $snippet "NSPasteBoard" } } { "?" boolean } }
 { $description "Tests if the pasteboard holds a string." } ;
 
 HELP: pasteboard-string
index ec49f2e24a391609464fcbf749a6657529d70432..9a981d46cd9cf057d2f288eb516de6ba0b214c62 100644 (file)
@@ -1,5 +1,5 @@
-USING: classes compiler.tree.propagation.info help.markup help.syntax math
-math.intervals ;
+USING: classes compiler.tree.propagation.info help.markup
+help.syntax kernel math math.intervals ;
 IN: compiler.tree.propagation.known-words
 
 HELP: binary-op-class
@@ -27,7 +27,7 @@ HELP: number-valued
 { $description "Ensure that the class is a subclass of " { $link number } "." } ;
 
 HELP: fits-in-fixnum?
-{ $values { "interval" interval } { "?" "a boolean" } }
+{ $values { "interval" interval } { "?" boolean } }
 { $description "Checks if the interval is a subset of the " { $link fixnum } " interval. Used to see if arithmetic may overflow." }
 { $examples
   { $example
index 41386fd82ee87f2eb693791d7cb380e86049dd71..0cd23dc1b559a6a2ae2a961c759dcec7b5a41cb3 100644 (file)
@@ -6,28 +6,28 @@ HELP: <mailbox>
 { $description "A mailbox is an object that can be used for safe thread communication. Items can be put in the mailbox and retrieved in a FIFO order. If the mailbox is empty when a get operation is performed then the thread will block until another thread places something in the mailbox. If multiple threads are waiting on the same mailbox, only one of the waiting threads will be unblocked to thread the get operation." } ;\r
 \r
 HELP: mailbox-empty?\r
-{ $values { "mailbox" mailbox } \r
-          { "bool" "a boolean" }\r
+{ $values { "mailbox" mailbox }\r
+          { "bool" boolean }\r
 }\r
 { $description "Return true if the mailbox is empty." } ;\r
 \r
 HELP: mailbox-put\r
-{ $values { "obj" object } \r
-          { "mailbox" mailbox } \r
+{ $values { "obj" object }\r
+          { "mailbox" mailbox }\r
 }\r
 { $description "Put the object into the mailbox. Any threads that have a blocking get on the mailbox are resumed. Only one of those threads will successfully get the object, the rest will immediately block waiting for the next item in the mailbox." } ;\r
 \r
 HELP: block-unless-pred\r
 { $values\r
     { "mailbox" mailbox }\r
-    { "timeout" "a " { $link duration } " or " { $link f } }\r
-    { "pred" { $quotation ( ... message -- ... ? ) } } \r
+    { "timeout" { $maybe duration } }\r
+    { "pred" { $quotation ( ... message -- ... ? ) } }\r
 }\r
 { $description "Block the thread if there are no items in the mailbox that return true when the predicate is called with the item on the stack." } ;\r
 \r
 HELP: block-if-empty\r
-{ $values { "mailbox" mailbox } \r
-    { "timeout" "a " { $link duration } " or " { $link f } }\r
+{ $values { "mailbox" mailbox }\r
+    { "timeout" { $maybe duration } }\r
 }\r
 { $description "Block the thread if the mailbox is empty." } ;\r
 \r
index 3d7390ae2853590ae5d27be4e49f3f5756611a90..9760d842dca97ccbc9f81e7b6e879b37d99f2d98 100644 (file)
@@ -1,7 +1,6 @@
 ! Copyright (C) 2005, 2008 Chris Double, Slava Pestov.\r
 ! See http://factorcode.org/license.txt for BSD license.\r
-USING: concurrency.messaging kernel arrays\r
-continuations help.markup help.syntax quotations calendar ;\r
+USING: calendar help.markup help.syntax kernel ;\r
 IN: concurrency.promises\r
 \r
 HELP: promise\r
@@ -12,7 +11,7 @@ HELP: <promise>
 { $description "Creates a new promise which may be fulfilled by calling " { $link fulfill } "." } ;\r
 \r
 HELP: promise-fulfilled?\r
-{ $values { "promise" promise } { "?" "a boolean" } }\r
+{ $values { "promise" promise } { "?" boolean } }\r
 { $description "Tests if " { $link fulfill } " has previously been called on the promise, in which case " { $link ?promise } " will return immediately without blocking." } ;\r
 \r
 HELP: ?promise-timeout\r
index 9753f978d294e3c83bda22ce0ba62cd72198ffb1..f229278e119cc30a7ff1cf1742a38a0511e955d6 100644 (file)
@@ -1,5 +1,5 @@
-USING: assocs cpu.x86.assembler help.markup help.syntax literals math
-multiline system words ;
+USING: assocs cpu.x86.assembler help.markup help.syntax kernel
+literals math multiline system words ;
 IN: cpu.architecture
 
 <<
@@ -27,7 +27,7 @@ HELP: signed-rep
 { $description "Maps any representation to its signed counterpart, if it has one." } ;
 
 HELP: immediate-arithmetic?
-{ $values { "n" number } { "?" "a boolean" } }
+{ $values { "n" number } { "?" boolean } }
 { $description
   "Can this value be an immediate operand for " { $link %add-imm } ", "
   { $link %sub-imm } ", or " { $link %mul-imm } "?"
@@ -42,7 +42,7 @@ HELP: vm-stack-space
 { $description "Parameter space to reserve in anything making VM calls." } ;
 
 HELP: complex-addressing?
-{ $values { "?" "a boolean" } }
+{ $values { "?" boolean } }
 { $description "Specifies if " { $link %slot } ", " { $link %set-slot } " and " { $link %write-barrier } " accept the 'scale' and 'tag' parameters, and if %load-memory and %store-memory work." } ;
 
 HELP: param-regs
@@ -63,7 +63,7 @@ HELP: %box-alien
 { $examples { $unchecked-example $[ ex-%box-alien ] } } ;
 
 HELP: fused-unboxing?
-{ $values { "?" "a boolean" } }
+{ $values { "?" boolean } }
 { $description "Whether this architecture support " { $link %load-float } ", " { $link %load-double } ", and " { $link %load-vector } "." } ;
 
 HELP: return-regs
index 96a0575926c068b8718851e076cd8287c1e6d4a0..1738c2bb59c8ce324fe3cc319eb0620838021363 100644 (file)
@@ -1,5 +1,4 @@
-USING: help.syntax help.markup kernel prettyprint sequences
-io.pathnames strings ;
+USING: help.markup help.syntax io.pathnames quotations strings ;
 IN: csv
 
 HELP: read-row
@@ -48,7 +47,7 @@ HELP: write-csv
 
 HELP: with-delimiter
 { $values { "ch" "field delimiter (e.g. CHAR: \\t)" }
-          { "quot" "a quotation" } }
+          { "quot" quotation } }
 { $description "Sets the field delimiter for read-csv, read-row, write-csv, or write-row words." } ;
 
 ARTICLE: "csv" "Comma-separated-values parsing and writing"
index ece3e07f30b333bda6adcca2e25d10d092cb8726..cb697a7db75929c624f59672a7ffc282bfa76a74 100644 (file)
@@ -107,7 +107,7 @@ HELP: advance-row
 { $description "Advanced the pointer to an underlying SQL result set stored in a " { $link result-set } " object." } ;
 
 HELP: more-rows?
-{ $values { "result-set" result-set } { "?" "a boolean" } }
+{ $values { "result-set" result-set } { "?" boolean } }
 { $description "Returns true if the " { $link result-set } " has more rows to traverse." } ;
 
 
@@ -123,7 +123,7 @@ HELP: in-transaction
 
 HELP: in-transaction?
 { $values
-     { "?" "a boolean" } }
+     { "?" boolean } }
 { $description "Returns true if there is currently a transaction in progress in this scope." } ;
 
 HELP: query-each
index 2ac358982e76efb94ccbb14a29393c9e091733f4..60b032a02d60e8f4c5e3d62cdd1dfb14a0b1c089 100644 (file)
@@ -1,7 +1,6 @@
 ! Copyright (C) 2008 Doug Coleman.
 ! See http://factorcode.org/license.txt for BSD license.
-USING: classes hashtables help.markup help.syntax io.streams.string
-kernel sequences strings math ;
+USING: help.markup help.syntax kernel strings ;
 IN: db.types
 
 HELP: +db-assigned-id+
@@ -90,7 +89,7 @@ HELP: VARCHAR
 HELP: user-assigned-id-spec?
 { $values
      { "specs" "a sequence of SQL specs" }
-     { "?" "a boolean" } }
+     { "?" boolean } }
 { $description "Tests if any of the SQL specs has the type " { $link +user-assigned-id+ } "." } ;
 
 HELP: bind#
@@ -106,7 +105,7 @@ HELP: bind%
 HELP: db-assigned-id-spec?
 { $values
      { "specs" "a sequence of SQL specs" }
-     { "?" "a boolean" } }
+     { "?" boolean } }
 { $description "Tests if any of the SQL specs has the type " { $link +db-assigned-id+ } "." } ;
 
 HELP: find-primary-key
@@ -129,13 +128,13 @@ HELP: normalize-spec
 HELP: primary-key?
 { $values
      { "spec" "a SQL spec" }
-     { "?" "a boolean" } }
+     { "?" boolean } }
 { $description "Returns true if a SQL spec is a primary key." } ;
 
 HELP: relation?
 { $values
      { "spec" "a SQL spec" }
-     { "?" "a boolean" } }
+     { "?" boolean } }
 { $description "Returns true if a SQL spec is a relation." } ;
 
 HELP: unknown-modifier
index 50461226b55477bbb7b77bf7cbe294593ed74add..a1bfdcc9c6ab7eeec4e4f2cde3a9e3a61fbbb731 100644 (file)
@@ -1,7 +1,6 @@
-USING: alien arrays generic generic.math help.markup help.syntax
-kernel math memory strings sbufs vectors io io.files classes
-help generic.single continuations io.files.private listener
-alien.libraries ;
+USING: alien alien.libraries arrays continuations generic.math
+generic.single help help.markup help.syntax io kernel math
+quotations sbufs strings vectors ;
 IN: debugger
 
 ARTICLE: "debugger" "The debugger"
@@ -48,7 +47,7 @@ HELP: :c
 { $description "Prints the call stack at the time of the most recent error. Used for interactive debugging." } ;
 
 HELP: :get
-{ $values { "variable" "an object" } { "value" "the value, or f" } }
+{ $values { "variable" object } { "value" "the value, or f" } }
 { $description "Looks up the value of a variable at the time of the most recent error." } ;
 
 HELP: :res
@@ -84,7 +83,7 @@ HELP: restarts.
 { $description "Print a list of restarts for the most recently thrown error to " { $link output-stream } "." } ;
 
 HELP: try
-{ $values { "quot" "a quotation" } }
+{ $values { "quot" quotation } }
 { $description "Attempts to call a quotation; if it throws an error, the error is printed to " { $link output-stream } ", stacks are restored, and execution continues after the call to " { $link try } "." }
 { $examples
     "The following example prints an error and keeps going:"
index 8b86fd2f3f4f3241224e93a4c467ee0a3f6bedab..bb0b0743257283f3689938465d380b07376b3834 100644 (file)
@@ -3,7 +3,7 @@ quotations ;
 IN: deques
 
 HELP: deque-empty?
-{ $values { "deque" deque } { "?" "a boolean" } }
+{ $values { "deque" deque } { "?" boolean } }
 { $contract "Returns true if a deque is empty." }
 { $notes "This operation is O(1)." } ;
 
@@ -15,7 +15,7 @@ HELP: clear-deque
 HELP: deque-member?
 { $values
      { "value" object } { "deque" deque }
-     { "?" "a boolean" } }
+     { "?" boolean } }
 { $description "Returns true if the " { $snippet "value" } " is found in the deque." } ;
 
 HELP: push-front
index 589f99f6dc6ae8180667344170b65cf57788d58b..98ad9f23404ec7d1e4dcc3e6fa13de2b42af55e9 100644 (file)
@@ -14,7 +14,7 @@ HELP: equiv-set-size
 { $description "Outputs the number of elements in the equivalence class of " { $snippet "a" } "." } ;
 
 HELP: equiv?
-{ $values { "a" object } { "b" object } { "disjoint-set" disjoint-set } { "?" "a boolean" } }
+{ $values { "a" object } { "b" object } { "disjoint-set" disjoint-set } { "?" boolean } }
 { $description "Tests if two elements belong to the same equivalence class." } ;
 
 HELP: equate
index 5036441f60e244a3afa94a2f90a8619a5d364a6a..8138feee6a0e4c01ace27d4ab71ab57d0dee6b5d 100644 (file)
@@ -40,7 +40,7 @@ HELP: <hashed-dlist>
 { $description "Creates a new " { $link search-deque } " backed by a " { $link dlist } ", with a " { $link hashtable } " for fast membership tests." } ;
 
 HELP: dlist-find
-{ $values { "dlist" { $link dlist } } { "quot" quotation } { "obj/f" "an object or " { $link f } } { "?" "a boolean" } }
+{ $values { "dlist" { $link dlist } } { "quot" quotation } { "obj/f" "an object or " { $link f } } { "?" boolean } }
 { $description "Applies the quotation to each element of the " { $link dlist } " in turn, until it outputs a true value or the end of the " { $link dlist } " is reached.  Outputs either the object it found or " { $link f } ", and a boolean which is true if an object is found." }
 { $notes "Returns a boolean to allow dlists to store " { $link f } "."
     $nl
@@ -53,12 +53,12 @@ HELP: dlist-filter
 { $side-effects { "dlist" } } ;
 
 HELP: dlist-any?
-{ $values { "dlist" { $link dlist } } { "quot" quotation } { "?" "a boolean" } }
+{ $values { "dlist" { $link dlist } } { "quot" quotation } { "?" boolean } }
 { $description "Just like " { $link dlist-find } " except it doesn't return the object." }
 { $notes "This operation is O(n)." } ;
 
 HELP: delete-node-if*
-{ $values { "dlist" { $link dlist } } { "quot" quotation } { "obj/f" "an object or " { $link f } } { "?" "a boolean" } }
+{ $values { "dlist" { $link dlist } } { "quot" quotation } { "obj/f" "an object or " { $link f } } { "?" boolean } }
 { $description "Calls " { $link dlist-find } " on the " { $link dlist } " and deletes the node returned, if any.  Returns the value of the deleted node and a boolean to allow the deleted value to distinguished from " { $link f } ", for nothing deleted." }
 { $notes "This operation is O(n)." } ;
 
index 82ed0eb0a5a62992d077960b7fa10fcc36bc4d53..c540a149b3c56f51dfc88049dc9181f5f87af7d7 100644 (file)
@@ -1,4 +1,5 @@
-USING: help.markup help.syntax math models strings sequences ;
+USING: help.markup help.syntax kernel math models sequences
+strings ;
 IN: documents
 
 HELP: +col
@@ -20,7 +21,7 @@ HELP: =line
 { $description "Sets the line number of a line/column pair." } ;
 
 HELP: lines-equal?
-{ $values { "loc1" "a pair of integers" } { "loc2" "a pair of integers" } { "?" "a boolean" } }
+{ $values { "loc1" "a pair of integers" } { "loc2" "a pair of integers" } { "?" boolean } }
 { $description "Tests if both line/column pairs have the same line number." } ;
 
 HELP: document
index e2c96b981f2c360ce4d42b6f89962ecf80ca9184..7aa771e37d5aed908b41e772b288d680ad6e20f7 100644 (file)
@@ -36,7 +36,7 @@ HELP: encode-password
 HELP: have-capabilities?
 { $values
      { "capabilities" "a sequence of capabilities" }
-     { "?" "a boolean" }
+     { "?" boolean }
 }
 { $description "Tests if the currently logged-in user possesses the given capabilities." } ;
 
index a652e734a1faf886711d23cc965f423188e72a36..7758afd212834ba37d64f88b0435d995d1f9f8b8 100644 (file)
@@ -6,7 +6,7 @@ HELP: allow-deactivation
 { $description "Adds a " { $snippet "deactivate-user" } " action to an authentication realm." } ;
 
 HELP: allow-deactivation?
-{ $values { "?" "a boolean" } }
+{ $values { "?" boolean } }
 { $description "Outputs true if the current authentication realm allows user profile deactivation." } ;
 
 ARTICLE: "furnace.auth.features.deactivate-user" "User profile deactivation"
index 1124ad43eca59ecb06c7e42709046e15e4441f19..be1276239c3b9a5254670bd469b947beae4adbfb 100644 (file)
@@ -6,7 +6,7 @@ HELP: allow-edit-profile
 { $description "Adds an " { $snippet "edit-profile" } " action to an authentication realm." } ;
 
 HELP: allow-edit-profile?
-{ $values { "?" "a boolean" } }
+{ $values { "?" boolean } }
 { $description "Outputs true if the current authentication realm allows user profile editing." } ;
 
 ARTICLE: "furnace.auth.features.edit-profile" "User profile editing"
index 22fa95f23e20d198de58b66bcef37f9b643a06b5..3248bb1952ed2fcd84e0c551f17d0d728112158c 100644 (file)
@@ -6,7 +6,7 @@ HELP: allow-password-recovery
 { $description "Adds a " { $snippet "recover-password" } " action to an authentication realm." } ;
 
 HELP: allow-password-recovery?
-{ $values { "?" "a boolean" } }
+{ $values { "?" boolean } }
 { $description "Outputs true if the current authentication realm allows user password recovery." } ;
 
 HELP: lost-password-from
index d64a14c8690f1f847cd1ab2481400d8ec90c6d9e..49f397c829888753932ce9904c33fbabdcb13ffd 100644 (file)
@@ -6,7 +6,7 @@ HELP: allow-registration
 { $description "Adds a " { $snippet "registration" } " action to an authentication realm." } ;
 
 HELP: allow-registration?
-{ $values { "?" "a boolean" } }
+{ $values { "?" boolean } }
 { $description "Outputs true if the current authentication realm allows user registration." } ;
 
 ARTICLE: "furnace.auth.features.registration" "User registration"
index 1d6f90a8e2465ed6098958dfd46dc2ec9278cdc8..1e5d89f8896d3309ecbcd87f1444c76b617dc504 100644 (file)
@@ -72,7 +72,7 @@ HELP: resolve-template-path
 { $description "Resolves a responder-relative template path." } ;
 
 HELP: same-host?
-{ $values { "url" url } { "?" "a boolean" } }
+{ $values { "url" url } { "?" boolean } }
 { $description "Tests if the given URL is located on the same host as the URL of the current request." } ;
 
 HELP: user-agent
index 078721937f7b5fb6ae934bd18a245c04f4a0dd56..58cc35af1c4e2b6cd7965d61946cba1771543155 100644 (file)
@@ -47,7 +47,7 @@ HELP: close-game-input
 { $description "Closes the game input interface, releasing any allocated resources. Once this word is called, any remaining " { $link controller } " objects are invalid." } ;
 
 HELP: game-input-opened?
-{ $values { "?" "a boolean" } }
+{ $values { "?" boolean } }
 { $description "Returns true if the game input interface is open, false otherwise." } ;
 
 HELP: with-game-input
index f22dbf9e0a76b5c9af63c7e7248cf6f5fca90e70..2401db1a1a02532d1302f64f9689b51a30f2ce39 100644 (file)
@@ -1,4 +1,4 @@
-USING: help.markup help.syntax sequences strings ;
+USING: help.markup help.syntax kernel sequences strings ;
 IN: grouping
 
 ARTICLE: "grouping" "Groups and clumps"
@@ -65,7 +65,7 @@ $nl
 "New groups are created by calling " { $link <groups> } "." } ;
 
 HELP: group
-{ $values { "seq" "a sequence" } { "n" "a non-negative integer" } { "array" "a sequence of sequences" } }
+{ $values { "seq" sequence } { "n" "a non-negative integer" } { "array" "a sequence of sequences" } }
 { $description "Splits the sequence into disjoint groups of " { $snippet "n" } " elements and collects the groups into a new array." }
 { $notes "If the sequence length is not a multiple of " { $snippet "n" } ", the final subsequence in the list will be shorter than " { $snippet "n" } " elements." }
 { $examples
@@ -73,7 +73,7 @@ HELP: group
 } ;
 
 HELP: <groups>
-{ $values { "seq" "a sequence" } { "n" "a non-negative integer" } { "groups" groups } }
+{ $values { "seq" sequence } { "n" "a non-negative integer" } { "groups" groups } }
 { $description "Outputs a virtual sequence whose elements are slices of disjoint subsequences of " { $snippet "n" } " elements from the underlying sequence." }
 { $examples
     { $example
@@ -100,7 +100,7 @@ $nl
 "New clumps are created by calling " { $link <circular-clumps> } "." } ;
 
 HELP: clump
-{ $values { "seq" "a sequence" } { "n" "a non-negative integer" } { "array" "a sequence of sequences" } }
+{ $values { "seq" sequence } { "n" "a non-negative integer" } { "array" "a sequence of sequences" } }
 { $description "Splits the sequence into overlapping clumps of " { $snippet "n" } " elements and collects the clumps into a new array." }
 { $notes "For an empty sequence, the result is an empty sequence. For a non empty sequence with a length smaller than " { $snippet "n" } ", the result will be an empty sequence." }
 { $examples
@@ -108,7 +108,7 @@ HELP: clump
 } ;
 
 HELP: circular-clump
-{ $values { "seq" "a sequence" } { "n" "a non-negative integer" } { "array" "a sequence of sequences" } }
+{ $values { "seq" sequence } { "n" "a non-negative integer" } { "array" "a sequence of sequences" } }
 { $description "Splits the sequence into overlapping clumps of " { $snippet "n" } " elements, wrapping around the end of the sequence, and collects the clumps into a new array." }
 { $notes "For an empty sequence, the result is an empty sequence." }
 { $examples
@@ -116,7 +116,7 @@ HELP: circular-clump
 } ;
 
 HELP: <clumps>
-{ $values { "seq" "a sequence" } { "n" "a non-negative integer" } { "clumps" clumps } }
+{ $values { "seq" sequence } { "n" "a non-negative integer" } { "clumps" clumps } }
 { $description "Outputs a virtual sequence whose elements are overlapping subsequences of " { $snippet "n" } " elements from the underlying sequence." }
 { $examples
     "Running averages:"
@@ -136,7 +136,7 @@ HELP: <clumps>
 } ;
 
 HELP: <circular-clumps>
-{ $values { "seq" "a sequence" } { "n" "a non-negative integer" } { "clumps" clumps } }
+{ $values { "seq" sequence } { "n" "a non-negative integer" } { "clumps" clumps } }
 { $description "Outputs a virtual sequence whose elements are overlapping slices of " { $snippet "n" } " elements from the underlying sequence, starting with each of its elements and wrapping around the end of the sequence." }
 { $examples
     { $example
@@ -153,7 +153,7 @@ HELP: <circular-clumps>
 { <clumps> <circular-clumps> <groups> } related-words
 
 HELP: monotonic?
-{ $values { "seq" sequence } { "quot" { $quotation ( elt1 elt2 -- ? ) } } { "?" "a boolean" } }
+{ $values { "seq" sequence } { "quot" { $quotation ( elt1 elt2 -- ? ) } } { "?" boolean } }
 { $description "Applies the relation to successive pairs of elements in the sequence, testing for a truth value. The relation should be a transitive relation, such as a total order or an equality relation." }
 { $examples
     "Testing if a sequence is non-decreasing:"
@@ -163,11 +163,11 @@ HELP: monotonic?
 } ;
 
 HELP: all-equal?
-{ $values { "seq" sequence } { "?" "a boolean" } }
+{ $values { "seq" sequence } { "?" boolean } }
 { $description "Tests if all elements in the sequence are equal. Yields true with an empty sequence." } ;
 
 HELP: all-eq?
-{ $values { "seq" sequence } { "?" "a boolean" } }
+{ $values { "seq" sequence } { "?" boolean } }
 { $description "Tests if all elements in the sequence are the same identical object. Yields true with an empty sequence." } ;
 
 { monotonic? all-eq? all-equal? } related-words
index 8ceb7bb78ff45893a3389d57b67baa534867fc4b..3888951f6bd36045ea8153573ea13d73e263beae 100644 (file)
@@ -53,49 +53,49 @@ HELP: <max-heap>
 { $description "Create a new " { $link max-heap } "." } ;
 
 HELP: heap-push
-{ $values { "value" object } { "key" "a comparable object" } { "heap" "a heap" } }
+{ $values { "value" object } { "key" "a comparable object" } { "heap" heap } }
 { $description "Push a pair onto a heap. The key must be comparable with all other keys by the " { $link <=> } " generic word." }
 { $side-effects "heap" } ;
 
 HELP: heap-push*
-{ $values { "value" object } { "key" "a comparable object" } { "heap" "a heap" } { "entry" entry } }
+{ $values { "value" object } { "key" "a comparable object" } { "heap" heap } { "entry" entry } }
 { $description "Push a pair onto a heap, and output an entry which may later be passed to " { $link heap-delete } "." }
 { $side-effects "heap" } ;
 
 HELP: heap-push-all
-{ $values { "assoc" assoc } { "heap" "a heap" } }
+{ $values { "assoc" assoc } { "heap" heap } }
 { $description "Push every key/value pair of an assoc onto a heap." }
 { $side-effects "heap" } ;
 
 HELP: heap-peek
-{ $values { "heap" "a heap" } { "value" object } { "key" object } }
+{ $values { "heap" heap } { "value" object } { "key" object } }
 { $description "Output the first element in the heap, leaving it in the heap." } ;
 
 HELP: heap-pop*
-{ $values { "heap" "a heap" } }
+{ $values { "heap" heap } }
 { $description "Remove the first element from the heap." }
 { $side-effects "heap" } ;
 
 HELP: heap-pop
-{ $values { "heap" "a heap" } { "value" object } { "key" object } }
+{ $values { "heap" heap } { "value" object } { "key" object } }
 { $description "Output and remove the first element in the heap." }
 { $side-effects "heap" } ;
 
 HELP: heap-empty?
-{ $values { "heap" "a heap" } { "?" "a boolean" } }
+{ $values { "heap" heap } { "?" boolean } }
 { $description "Tests if a heap has no nodes." } ;
 
 HELP: heap-size
-{ $values { "heap" "a heap" } { "n" integer } }
+{ $values { "heap" heap } { "n" integer } }
 { $description "Returns the number of key/value pairs in the heap." } ;
 
 HELP: heap-delete
-{ $values { "entry" entry } { "heap" "a heap" } }
+{ $values { "entry" entry } { "heap" heap } }
 { $description "Remove the specified entry from the heap." }
 { $errors "Throws an error if the entry is from another heap or if it has already been deleted." }
 { $side-effects "heap" } ;
 
 HELP: slurp-heap
 { $values
-     { "heap" "a heap" } { "quot" quotation } }
+     { "heap" heap } { "quot" quotation } }
 { $description "Removes values from a heap and processes them with the quotation until the heap is empty." } ;
index 6cff585eee1a33e12fc9af58b3551571301a9184..9b0528080af1a36584bb67d7fa255041321c7cf4 100644 (file)
@@ -1,6 +1,6 @@
-USING: help.markup help.crossref help.stylesheet help.topics
-help.syntax definitions io prettyprint summary arrays math
-sequences vocabs strings see ;
+USING: arrays help.crossref help.markup help.stylesheet
+help.syntax help.topics io kernel math prettyprint quotations
+see sequences strings summary vocabs ;
 IN: help
 
 ARTICLE: "printing-elements" "Printing markup elements"
@@ -239,11 +239,11 @@ HELP: simple-element
 { $class-description "Class of simple elements, which are just arrays of elements." } ;
 
 HELP: ($span)
-{ $values { "quot" "a quotation" } }
+{ $values { "quot" quotation } }
 { $description "Prints an inline markup element." } ;
 
 HELP: ($block)
-{ $values { "quot" "a quotation" } }
+{ $values { "quot" quotation } }
 { $description "Prints a block markup element with newlines before and after." } ;
 
 HELP: $heading
@@ -340,7 +340,7 @@ HELP: $link
 } ;
 
 HELP: textual-list
-{ $values { "seq" "a sequence" } { "quot" { $quotation ( elt -- ) } } }
+{ $values { "seq" sequence } { "quot" { $quotation ( elt -- ) } } }
 { $description "Applies the quotation to each element of the sequence, printing a comma between each pair of elements." }
 { $examples
     { $example "USING: help.markup io namespaces ;" "last-element off" "{ \"fish\" \"chips\" \"salt\" } [ write ] textual-list" "fish, chips, salt" }
@@ -487,7 +487,7 @@ HELP: HELP:
 
 HELP: ARTICLE:
 { $syntax "ARTICLE: topic title content... ;" }
-{ $values { "topic" "an object" } { "title" "a string" } { "content" "markup elements" } }
+{ $values { "topic" object } { "title" string } { "content" "markup elements" } }
 { $description "Defines a help article. String topic names are reserved for core documentation. Contributed modules should name articles by arrays, where the first element of an array identifies the module; for example, " { $snippet "{ \"httpd\" \"intro\" }" } "." }
 { $examples
     { $code
index 60cba2fc881508afc6cc19a7623a7aab9b1281e8..afbcc7c849b528f877187ed49855911b66201b6f 100644 (file)
@@ -16,7 +16,7 @@ GENERIC: word-help* ( word -- content )
     ] ?if ;
 
 : $predicate ( element -- )
-    { { "object" object } { "?" "a boolean" } } $values
+    { { "object" object } { "?" boolean } } $values
     [
         "Tests if the object is an instance of the " ,
         first "predicating" word-prop <$link> ,
index 82cf78e70d9e759d8759bf3fb7c2d1daa83294f4..74dd40580638864896f40cc14ac52bde583831b3 100644 (file)
@@ -1,5 +1,5 @@
-USING: help.markup help.syntax help.crossref help io io.styles
-hashtables strings ;
+USING: help help.crossref help.markup help.syntax io.styles
+sequences strings words ;
 IN: help.topics
 
 HELP: articles
@@ -23,11 +23,11 @@ HELP: article-content
 { $description "Outputs the content of a specific help article." } ;
 
 HELP: all-articles
-{ $values { "seq" "a sequence" } }
+{ $values { "seq" sequence } }
 { $description "Outputs a sequence of all help article names, and all words with documentation." } ;
 
 HELP: elements
-{ $values { "elt-type" "a word" } { "element" "a markup element" } { "seq" "a new sequence" } }
+{ $values { "elt-type" word } { "element" "a markup element" } { "seq" "a new sequence" } }
 { $description "Outputs a sequence of all elements of type " { $snippet "elt-type" } " found by traversing " { $snippet "element" } "." } ;
 
 HELP: collect-elements
index 9203ad31ae937be50fded6823925ef723cb4a4b0..bc678191bae118b39ad6f80c8328a37d5a5d6164 100644 (file)
@@ -1,5 +1,6 @@
+USING: assocs help.markup help.syntax kernel quotations strings
+;
 IN: html.forms
-USING: help.markup help.syntax strings quotations kernel assocs ;
 
 HELP: <form>
 { $values { "form" form } }
@@ -78,7 +79,7 @@ HELP: with-each-object
 { $notes "This word is used to implement the " { $snippet "t:bind-each" } " tag of the " { $vocab-link "html.templates.chloe" } " templating system. It can also be called directly from " { $vocab-link "html.templates.fhtml" } " templates." } ;
 
 HELP: validation-failed?
-{ $values { "?" "a boolean" } }
+{ $values { "?" boolean } }
 { $description "Tests if validation of the current form failed." } ;
 
 HELP: validate-values
index 5d1b231f60914fe6fc185aad7bce889cffb6626a..00b76f8b5179ebab6eaa6c8bd9a55fe0786cb096 100644 (file)
@@ -1,5 +1,5 @@
-USING: help.markup help.syntax io.streams.string quotations strings urls
-http vocabs.refresh math io.servers assocs ;
+USING: assocs help.markup help.syntax http io.servers kernel
+math strings urls vocabs.refresh ;
 IN: http.server
 
 HELP: trivial-responder
@@ -32,7 +32,7 @@ HELP: main-responder
 { $var-description "The responder which will handle HTTP requests." } ;
 
 HELP: post-request?
-{ $values { "?" "a boolean" } }
+{ $values { "?" boolean } }
 { $description "Outputs if the current request is a POST request.s" } ;
 
 HELP: responder-nesting
index 64fc40d4b9c8dc402bdb6c22fe7e929fdd287494..a4603bff0321a0a53fe4512448358f74bad31138 100644 (file)
@@ -1,6 +1,6 @@
 ! Copyright (C) 2008, 2009 Daniel Ehrenberg.\r
 ! See http://factorcode.org/license.txt for BSD license.\r
-USING: help.markup help.syntax assocs kernel sequences ;\r
+USING: assocs help.markup help.syntax kernel sequences ;\r
 IN: interval-maps\r
 \r
 HELP: interval-at*\r
@@ -12,7 +12,7 @@ HELP: interval-at
 { $description "Looks up a key in an interval map, returning the value of the corresponding interval, or f if the interval is not present in the map." } ;\r
 \r
 HELP: interval-key?\r
-{ $values { "key" object } { "map" interval-map } { "?" "a boolean" } }\r
+{ $values { "key" object } { "map" interval-map } { "?" boolean } }\r
 { $description "Tests whether an object is in an interval in the interval map, returning t if the object is present." } ;\r
 \r
 HELP: <interval-map>\r
index 961409a11dfab4ad6b6bf7a16404bf6dc64fdbc0..adda3838cc03234966968c9b1cc791c5ad46824e 100644 (file)
@@ -1,38 +1,38 @@
-USING: help.syntax help.markup ;
+USING: help.markup help.syntax kernel quotations words ;
 IN: inverse
 
 HELP: [undo]
-{ $values { "quot" "a quotation" } { "undo" "the inverse of the quotation" } }
+{ $values { "quot" quotation } { "undo" "the inverse of the quotation" } }
 { $description "Creates the inverse of the given quotation" }
 { $see-also undo } ;
 
 HELP: undo
-{ $values { "quot" "a quotation" } }
+{ $values { "quot" quotation } }
 { $description "Executes the inverse of the given quotation" }
 { $see-also [undo] } ;
 
 HELP: define-inverse
-{ $values { "word" "a word" } { "quot" "the inverse" } }
+{ $values { "word" word } { "quot" "the inverse" } }
 { $description "Defines the inverse of a given word, taking no arguments from the quotation, only the stack." }
 { $see-also define-dual define-involution define-pop-inverse } ;
 
 HELP: define-dual
-{ $values { "word1" "a word" } { "word2" "a word" } }
+{ $values { "word1" word } { "word2" word } }
 { $description "Defines the inverse of each word as being the other one." }
 { $see-also define-inverse define-involution } ;
 
 HELP: define-involution
-{ $values { "word" "a word" } }
+{ $values { "word" word } }
 { $description "Defines a word as being its own inverse." }
 { $see-also define-dual define-inverse } ;
 
 HELP: define-pop-inverse
-{ $values { "word" "a word" } { "n" "number of arguments to be taken from the inverted quotation" } { "quot" "a quotation" } }
+{ $values { "word" word } { "n" "number of arguments to be taken from the inverted quotation" } { "quot" quotation } }
 { $description "Defines the inverse of the given word, taking the given number of arguments from the inverted quotation. The quotation given should generate an inverse quotation." }
 { $see-also define-inverse } ;
 
 HELP: matches?
-{ $values { "quot" "a quotation" } { "?" "a boolean" } }
+{ $values { "quot" quotation } { "?" boolean } }
 { $description "Tests if the stack can match the given quotation. The quotation is inverted, and if the inverse can run without a unification failure, then t is returned. Else f is returned. If a different error is encountered (such as stack underflow), this will be propagated." } ;
 
 HELP: switch
index d9fbc683c332818958c85ccbc1d8464f202f9be3..d27e0bf59e4babdf8a3154fed59f1fb2d1b1971e 100644 (file)
@@ -1,4 +1,5 @@
-USING: help.markup help.syntax byte-arrays alien destructors ;
+USING: alien byte-arrays destructors help.markup help.syntax
+kernel ;
 IN: io.buffers
 
 ARTICLE: "buffers" "Locked I/O buffers"
@@ -101,7 +102,7 @@ HELP: buffer-capacity
 } ;
 
 HELP: buffer-empty?
-{ $values { "buffer" buffer } { "?" "a boolean" } }
+{ $values { "buffer" buffer } { "?" boolean } }
 { $description "Tests if the buffer contains no more data to be read or written." } ;
 
 HELP: >buffer
index 7e57d66b99a099b2bf417865bc749a06db9ccab2..e54588a1b507839bb819a3a5b4bba862b7d1bd21 100644 (file)
@@ -13,15 +13,15 @@ HELP: link-info
 { file-info link-info } related-words
 
 HELP: directory?
-{ $values { "file-info" file-info } { "?" "a boolean" } }
+{ $values { "file-info" file-info } { "?" boolean } }
 { $description "Tests if " { $snippet "file-info" } " is a directory." } ;
 
 HELP: regular-file?
-{ $values { "file-info" file-info } { "?" "a boolean" } }
+{ $values { "file-info" file-info } { "?" boolean } }
 { $description "Tests if " { $snippet "file-info" } " is a normal file." } ;
 
 HELP: symbolic-link?
-{ $values { "file-info" file-info } { "?" "a boolean" } }
+{ $values { "file-info" file-info } { "?" boolean } }
 { $description "Tests if " { $snippet "file-info" } " is a symbolic link." } ;
 
 HELP: file-systems
index 425f76b18d9e8799189b85c1767583925756bcf0..01ee8f4113cec892fbc14e4654bc815eacaff755 100644 (file)
@@ -1,7 +1,7 @@
 ! Copyright (C) 2008 Doug Coleman.
 ! See http://factorcode.org/license.txt for BSD license.
-USING: classes help.markup help.syntax io.streams.string
-strings math calendar io.files.info io.files.info.unix ;
+USING: calendar help.markup help.syntax io.files.info kernel
+math strings ;
 IN: io.files.info.unix
 
 HELP: add-file-permissions
@@ -49,37 +49,37 @@ HELP: file-user-id
 HELP: group-execute?
 { $values
      { "obj" "a pathname string or an integer" }
-     { "?" "a boolean" } }
+     { "?" boolean } }
 { $description "Tests whether the " { $snippet "group execute" } " bit is set on a file, " { $link file-info } ", or an integer." } ;
 
 HELP: group-read?
 { $values
      { "obj" "a pathname string, file-info object, or an integer" }
-     { "?" "a boolean" } }
+     { "?" boolean } }
 { $description "Tests whether the " { $snippet "group read" } " bit is set on a file, " { $link file-info } ", or an integer." } ;
 
 HELP: group-write?
 { $values
      { "obj" "a pathname string, file-info object, or an integer" }
-     { "?" "a boolean" } }
+     { "?" boolean } }
 { $description "Tests whether the " { $snippet "group write" } " bit is set on a file, " { $link file-info } ", or an integer." } ;
 
 HELP: other-execute?
 { $values
      { "obj" "a pathname string, file-info object, or an integer" }
-     { "?" "a boolean" } }
+     { "?" boolean } }
 { $description "Tests whether the " { $snippet "other execute" } " bit is set on a file, " { $link file-info } ", or an integer." } ;
 
 HELP: other-read?
 { $values
      { "obj" "a pathname string, file-info object, or an integer" }
-     { "?" "a boolean" } }
+     { "?" boolean } }
 { $description "Tests whether the " { $snippet "other read" } " bit is set on a file, " { $link file-info } ", or an integer." } ;
 
 HELP: other-write?
 { $values
      { "obj" "a pathname string, file-info object, or an integer" }
-     { "?" "a boolean" } }
+     { "?" boolean } }
 { $description "Tests whether the " { $snippet "other write" } " bit is set on a file, " { $link file-info } ", or an integer." } ;
 
 HELP: set-file-access-time
@@ -130,98 +130,98 @@ HELP: set-file-modified-time
 
 HELP: set-gid
 { $values
-     { "path" "a pathname string" } { "?" "a boolean" } }
+     { "path" "a pathname string" } { "?" boolean } }
 { $description "Sets the " { $snippet "gid" } " bit of a file to true or false." } ;
 
 HELP: gid?
 { $values
      { "obj" "a pathname string, file-info object, or an integer" }
-     { "?" "a boolean" } }
+     { "?" boolean } }
 { $description "Tests whether the " { $snippet "gid" } " bit is set on a file, " { $link file-info } ", or an integer." } ;
 
 HELP: set-group-execute
 { $values
-     { "path" "a pathname string" } { "?" "a boolean" } }
+     { "path" "a pathname string" } { "?" boolean } }
 { $description "Sets the " { $snippet "group execute" } " bit of a file to true or false." } ;
 
 HELP: set-group-read
 { $values
-     { "path" "a pathname string" } { "?" "a boolean" } }
+     { "path" "a pathname string" } { "?" boolean } }
 { $description "Sets the " { $snippet "group read" } " bit of a file to true or false." } ;
 
 HELP: set-group-write
 { $values
-     { "path" "a pathname string" } { "?" "a boolean" } }
+     { "path" "a pathname string" } { "?" boolean } }
 { $description "Sets the " { $snippet "group write" } " bit of a file to true or false." } ;
 
 HELP: set-other-execute
 { $values
-     { "path" "a pathname string" } { "?" "a boolean" } }
+     { "path" "a pathname string" } { "?" boolean } }
 { $description "Sets the " { $snippet "other execute" } " bit of a file to true or false." } ;
 
 HELP: set-other-read
 { $values
-     { "path" "a pathname string" } { "?" "a boolean" } }
+     { "path" "a pathname string" } { "?" boolean } }
 { $description "Sets the " { $snippet "other read" } " bit of a file to true or false." } ;
 
 HELP: set-other-write
 { $values
-     { "path" "a pathname string" } { "?" "a boolean" } }
+     { "path" "a pathname string" } { "?" boolean } }
 { $description "Sets the " { $snippet "other execute" } " bit of a file to true or false." } ;
 
 HELP: set-sticky
 { $values
-     { "path" "a pathname string" } { "?" "a boolean" } }
+     { "path" "a pathname string" } { "?" boolean } }
 { $description "Sets the " { $snippet "sticky" } " bit of a file to true or false." } ;
 
 HELP: sticky?
 { $values
      { "obj" "a pathname string, file-info object, or an integer" }
-     { "?" "a boolean" } }
+     { "?" boolean } }
 { $description "Tests whether the " { $snippet "sticky" } " bit is set on a file, " { $link file-info } ", or an integer." } ;
 
 HELP: set-uid
 { $values
-     { "path" "a pathname string" } { "?" "a boolean" } }
+     { "path" "a pathname string" } { "?" boolean } }
 { $description "Sets the " { $snippet "uid" } " bit of a file to true or false." } ;
 
 HELP: uid?
 { $values
      { "obj" "a pathname string, file-info object, or an integer" }
-     { "?" "a boolean" } }
+     { "?" boolean } }
 { $description "Tests whether the " { $snippet "uid" } " bit is set on a file, " { $link file-info } ", or an integer." } ;
 
 HELP: set-user-execute
 { $values
-     { "path" "a pathname string" } { "?" "a boolean" } }
+     { "path" "a pathname string" } { "?" boolean } }
 { $description "Sets the " { $snippet "user execute" } " bit of a file to true or false." } ;
 
 HELP: set-user-read
 { $values
-     { "path" "a pathname string" } { "?" "a boolean" } }
+     { "path" "a pathname string" } { "?" boolean } }
 { $description "Sets the " { $snippet "user read" } " bit of a file to true or false." } ;
 
 HELP: set-user-write
 { $values
-     { "path" "a pathname string" } { "?" "a boolean" } }
+     { "path" "a pathname string" } { "?" boolean } }
 { $description "Sets the " { $snippet "user write" } " bit of a file to true or false." } ;
 
 HELP: user-execute?
 { $values
      { "obj" "a pathname string, file-info object, or an integer" }
-     { "?" "a boolean" } }
+     { "?" boolean } }
 { $description "Tests whether the " { $snippet "user execute" } " bit is set on a file, " { $link file-info } ", or an integer." } ;
 
 HELP: user-read?
 { $values
      { "obj" "a pathname string, file-info object, or an integer" }
-     { "?" "a boolean" } }
+     { "?" boolean } }
 { $description "Tests whether the " { $snippet "user read" } " bit is set on a file, " { $link file-info } ", or an integer." } ;
 
 HELP: user-write?
 { $values
      { "obj" "a pathname string, file-info object, or an integer" }
-     { "?" "a boolean" } }
+     { "?" boolean } }
 { $description "Tests whether the " { $snippet "user write" } " bit is set on a file, " { $link file-info } ", or an integer." } ;
 
 ARTICLE: "unix-file-permissions" "Unix file permissions"
index 7e8d166b3213a75ff2d1db5a9fc2e3952920dbe5..0dc85d6b04f7885964dc3810aad00d19db0d1b5a 100644 (file)
@@ -1,6 +1,4 @@
-USING: help.markup help.syntax io io.ports kernel math
-io.pathnames io.directories math.parser io.files strings
-quotations io.files.unique.private ;
+USING: help.markup help.syntax quotations strings ;
 IN: io.files.unique
 
 HELP: default-temporary-directory
@@ -24,7 +22,7 @@ HELP: unique-retries
 { unique-length unique-retries } related-words
 
 HELP: make-unique-file
-{ $values { "prefix" "a string" } { "suffix" "a string" }
+{ $values { "prefix" string } { "suffix" string }
 { "path" "a pathname string" } }
 { $description "Creates a file that is guaranteed not to exist in the directory stored in " { $link current-temporary-directory } ". The file name is composed of a prefix, a number of random digits and letters, and the suffix. Returns the full pathname." }
 { $errors "Throws an error if a new unique file cannot be created after a number of tries. The most likely error is incorrect directory permissions on the temporary directory." } ;
@@ -32,8 +30,8 @@ HELP: make-unique-file
 { unique-file make-unique-file cleanup-unique-file } related-words
 
 HELP: cleanup-unique-file
-{ $values { "prefix" "a string" } { "suffix" "a string" }
-{ "quot" "a quotation" } }
+{ $values { "prefix" string } { "suffix" string }
+{ "quot" quotation } }
 { $description "Creates a file with " { $link make-unique-file } " and calls the quotation with the path name on the stack." }
 { $notes "The unique file will be deleted after calling this word." } ;
 
@@ -43,7 +41,7 @@ HELP: unique-directory
 { $errors "Throws an error if the directory cannot be created after a number of tries. The most likely error is incorrect directory permissions on the temporary directory." } ;
 
 HELP: cleanup-unique-directory
-{ $values { "quot" "a quotation" } }
+{ $values { "quot" quotation } }
 { $description "Creates a directory with " { $link unique-directory } " and calls the quotation with the pathname on the stack using the " { $link with-temporary-directory } " combinator. The quotation can access the " { $link current-temporary-directory } " symbol for the name of the temporary directory. Subsequent unique files will be created in this unique directory until the combinator returns." }
 { $notes "The directory will be deleted after calling this word, even if an error is thrown in the quotation. This combinator is like " { $link with-unique-directory } " but does not delete the directory." } ;
 
index 4fd616cca1ae00028f0aa50e83b5b8900701fb8b..687478a59f0b683023075a2fd03adfcdd51decd4 100644 (file)
@@ -1,6 +1,6 @@
 IN: io.monitors\r
-USING: help.markup help.syntax continuations destructors\r
-concurrency.mailboxes quotations ;\r
+USING: concurrency.mailboxes destructors help.markup help.syntax\r
+kernel quotations ;\r
 \r
 HELP: with-monitors\r
 { $values { "quot" quotation } }\r
@@ -8,12 +8,12 @@ HELP: with-monitors
 { $errors "Throws an error if the platform does not support file system change monitors." } ;\r
 \r
 HELP: <monitor>\r
-{ $values { "path" "a pathname string" } { "recursive?" "a boolean" } { "monitor" "a new monitor" } }\r
+{ $values { "path" "a pathname string" } { "recursive?" boolean } { "monitor" "a new monitor" } }\r
 { $contract "Opens a file system change monitor which listens for changes on " { $snippet "path" } ". The boolean indicates whether changes in subdirectories should be reported." }\r
 { $errors "Throws an error if the pathname does not exist, if a monitor could not be created or if the platform does not support monitors." } ;\r
 \r
 HELP: (monitor)\r
-{ $values { "path" "a pathname string" } { "recursive?" "a boolean" } { "mailbox" mailbox } { "monitor" "a new monitor" } }\r
+{ $values { "path" "a pathname string" } { "recursive?" boolean } { "mailbox" mailbox } { "monitor" "a new monitor" } }\r
 { $contract "Opens a file system change monitor which listens for changes on " { $snippet "path" } " and posts notifications to " { $snippet "mailbox" } " as triples with shape " { $snippet "{ path changed monitor } " } ". The boolean indicates whether changes in subdirectories should be reported." }\r
 { $errors "Throws an error if the pathname does not exist, if a monitor could not be created or if the platform does not support monitors." } ;\r
 \r
@@ -26,7 +26,7 @@ HELP: next-change
 { $errors "Throws an error if the monitor is closed from another thread." } ;\r
 \r
 HELP: with-monitor\r
-{ $values { "path" "a pathname string" } { "recursive?" "a boolean" } { "quot" { $quotation ( monitor -- ) } } }\r
+{ $values { "path" "a pathname string" } { "recursive?" boolean } { "quot" { $quotation ( monitor -- ) } } }\r
 { $description "Opens a file system change monitor and passes it to the quotation. Closes the monitor after the quotation returns or throws an error." }\r
 { $errors "Throws an error if the pathname does not exist, if a monitor could not be created or if the platform does not support monitors." } ;\r
 \r
index 2eb92804446983a2bbdc2e2258f5891a353c2450..d7f23c8be02a56fbd67aca47d087a9874b8ce934 100644 (file)
@@ -72,5 +72,5 @@ HELP: (wait-to-read)
 { $contract "Suspends the current thread until the port's buffer has data available for reading." } ;
 
 HELP: wait-to-read
-{ $values { "port" input-port } { "eof?" "a boolean" } }
+{ $values { "port" input-port } { "eof?" boolean } }
 { $description "If the port's buffer has unread data, returns immediately, otherwise suspends the current thread until some data is available for reading. If the buffer was empty and no more data could be read, outputs " { $link t } " to indicate end-of-file; otherwise outputs " { $link f } "." } ;
index 437bcfe9bb93dbdb24fbdd911222b742761b3b08..3b3ed75572e9e049d4880448f67ad6e851ba8121 100644 (file)
@@ -158,7 +158,7 @@ ARTICLE: "table-styles" "Table styles"
 } ;
 
 HELP: write-object
-{ $values { "str" string } { "obj" "an object" } }
+{ $values { "str" string } { "obj" object } }
 { $description "Writes a string to " { $link output-stream } ", associating it with the object. If formatted output is supported, the string will become a clickable presentation of the object, otherwise this word behaves like a call to " { $link write } "." }
 $io-error ;
 
index 6445f0a7cb814dbcc64bc99c63d3869d743b3ea4..5ceda1dcf148288ccb228405c2ae214bfbec3e42 100644 (file)
@@ -4,12 +4,12 @@ USING: help.markup help.syntax ;
 IN: json.writer
 
 HELP: >json
-{ $values { "obj" "an object" } { "string" "the object converted to JSON format" } }
+{ $values { "obj" object } { "string" "the object converted to JSON format" } }
 { $description "Serializes the object into a JSON formatted string." } 
 { $see-also json-print } ;
 
 HELP: json-print
-{ $values { "obj" "an object" } }
+{ $values { "obj" object } }
 { $description "Serializes the object into a JSON formatted string and outputs it to the standard output stream. 
 
 By default, tuples and hashtables are serialized into Javascript-friendly JSON formatted output by converting keys containing dashes into underscores. This behaviour can be modified by setting the dynamic variable " { $strong "jsvar-encode?" } " to false." } 
index d2c4e01bf80b3ed1d77dca3fa5c22d791dbd000e..4272b87c6c8209a1f72df191fe1768a85d94d477 100644 (file)
@@ -1,16 +1,16 @@
-USING: help.syntax help.markup ;\r
+USING: help.syntax help.markup sequences ;\r
 IN: lcs\r
 \r
 HELP: levenshtein\r
-{ $values { "old" "a sequence" } { "new" "a sequence" } { "n" "the Levenshtein distance" } }\r
+{ $values { "old" sequence } { "new" sequence } { "n" "the Levenshtein distance" } }\r
 { $description "Calculates the Levenshtein distance between old and new, that is, the minimal number of changes from the old sequence to the new one, in terms of deleting, inserting and replacing characters." } ;\r
 \r
 HELP: lcs\r
-{ $values { "seq1" "a sequence" } { "seq2" "a sequence" } { "lcs" "a longest common subsequence" } }\r
+{ $values { "seq1" sequence } { "seq2" sequence } { "lcs" "a longest common subsequence" } }\r
 { $description "Given two sequences, calculates a longest common subsequence between them. Note two things: this is only one of the many possible LCSs, and the LCS may not be contiguous." } ;\r
 \r
 HELP: diff\r
-{ $values { "old" "a sequence" } { "new" "a sequence" } { "diff" "an edit script" } }\r
+{ $values { "old" sequence } { "new" sequence } { "diff" "an edit script" } }\r
 { $description "Given two sequences, find a minimal edit script from the old to the new. There may be more than one minimal edit script, and this chooses one arbitrarily. This script is in the form of an array of the tuples of the classes " { $link retain } ", " { $link delete } " and " { $link insert } " which have their information stored in the 'item' slot." } ;\r
 \r
 HELP: retain\r
index 05865f495cb7ab8e8b5ca5b9504a1e1a5d85d453..a9b6789e9842eb2867c92cf72f611d8ffcc9a13a 100644 (file)
@@ -1,7 +1,8 @@
 ! Copyright (C) 2006 Chris Double.
 ! See http://factorcode.org/license.txt for BSD license.
-USING: help.markup help.syntax sequences strings lists ;
-IN: lists.lazy 
+USING: help.markup help.syntax kernel lists math sequences
+strings ;
+IN: lists.lazy
 
 ABOUT: "lists.lazy"
 
@@ -108,23 +109,23 @@ HELP: lappend
 { $description "Perform a similar functionality to that of the " { $link append } " word, but in a lazy manner. No evaluation of the list elements occurs initially but a " { $link <lazy-append> } " object is returned which conforms to the list protocol. Calling " { $link car } ", " { $link cdr } " or " { $link nil? } " on this will evaluate elements as required. Successive calls to " { $link cdr } " will iterate through list1, followed by list2." } ;
 
 HELP: lfrom-by
-{ $values { "n" "an integer" } { "quot" { $quotation ( n -- o ) } } { "lazy-from-by" "a lazy list of integers" } }
+{ $values { "n" integer } { "quot" { $quotation ( n -- o ) } } { "lazy-from-by" "a lazy list of integers" } }
 { $description "Return an infinite lazy list of values starting from n, with each successive value being the result of applying quot to the previous value." } ;
 
 HELP: lfrom
-{ $values { "n" "an integer" } { "list" "a lazy list of integers" } }
+{ $values { "n" integer } { "list" "a lazy list of integers" } }
 { $description "Return an infinite lazy list of incrementing integers starting from n." } ;
 
 HELP: sequence-tail>list
-{ $values { "index" "an integer 0 or greater" } { "seq" "a sequence" } { "list" "a list" } }
+{ $values { "index" "an integer 0 or greater" } { "seq" sequence } { "list" "a list" } }
 { $description "Convert the sequence into a list, starting from " { $snippet "index" } "." }
 { $see-also >list } ;
 
 HELP: >list
-{ $values { "object" "an object" } { "list" "a list" } }
+{ $values { "object" object } { "list" "a list" } }
 { $description "Convert the object into a list. Existing lists are passed through intact, sequences are converted using " { $link sequence-tail>list } " and other objects cause an error to be thrown." } 
 { $see-also sequence-tail>list } ;
-    
+
 { leach foldl lazy-map ltake lfilter lappend lfrom lfrom-by lconcat lcartesian-product lcartesian-product* lcomp lcomp* lmerge lwhile luntil } related-words
 
 HELP: lconcat
index 31e5329e980ab0e18405edd2dd685fac77fefc98..f34423f37deaebb6685909a513f24b7cf50cf006 100644 (file)
@@ -87,7 +87,7 @@ HELP: nil
 { $description "Returns a symbol representing the empty list" } ;
 
 HELP: nil?
-{ $values { "object" object } { "?" "a boolean" } }
+{ $values { "object" object } { "?" boolean } }
 { $description "Return true if the cons object is the nil cons." } ;
 
 { nil nil? } related-words
@@ -95,15 +95,15 @@ HELP: nil?
 { 1list 2list 3list } related-words
 
 HELP: 1list
-{ $values { "obj" "an object" } { "cons" list } }
+{ $values { "obj" object } { "cons" list } }
 { $description "Create a list with 1 element." } ;
 
 HELP: 2list
-{ $values { "a" "an object" } { "b" "an object" } { "cons" list } }
+{ $values { "a" object } { "b" object } { "cons" list } }
 { $description "Create a list with 2 elements." } ;
 
 HELP: 3list
-{ $values { "a" "an object" } { "b" "an object" } { "c" "an object" } { "cons" list } }
+{ $values { "a" object } { "b" object } { "c" object } { "cons" list } }
 { $description "Create a list with 3 elements." } ;
 
 HELP: lnth
@@ -131,11 +131,11 @@ HELP: leach
 { $description "Call the quotation for each item in the list." } ;
 
 HELP: foldl
-{ $values { "list" list } { "identity" "an object" } { "quot" { $quotation ( ... prev elt -- ... next ) } } { "result" "the final result" } }
+{ $values { "list" list } { "identity" object } { "quot" { $quotation ( ... prev elt -- ... next ) } } { "result" "the final result" } }
 { $description "Combines successive elements of the list (in a left-associative order) using a binary operation and outputs the final result." } ;
 
 HELP: foldr
-{ $values { "list" list } { "identity" "an object" } { "quot" { $quotation ( ... prev elt -- ... next ) } } { "result" "the final result" } }
+{ $values { "list" list } { "identity" object } { "quot" { $quotation ( ... prev elt -- ... next ) } } { "result" "the final result" } }
 { $description "Combines successive elements of the list (in a right-associative order) using a binary operation, and outputs the final result." } ;
 
 HELP: lmap
index 8600fb82bea2c415c9e086891652039719df181e..f1d515b4e2ef5e2001665ccf08930f7f8f738c96 100644 (file)
@@ -210,7 +210,7 @@ HELP: mask-bit
 HELP: mask?
 { $values
      { "x" integer } { "n" integer }
-     { "?" "a boolean" }
+     { "?" boolean }
 }
 { $description "Returns true if all of the bits in the mask " { $snippet "n" } " are set in the integer input " { $snippet "x" } "." }
 { $examples
@@ -310,7 +310,7 @@ HELP: unmask
 HELP: unmask?
 { $values
      { "x" integer } { "n" integer }
-     { "?" "a boolean" }
+     { "?" boolean }
 }
 { $description "Tests whether unmasking the bits in " { $snippet "x" } " would return an integer greater than zero." }
 { $examples
index ff2be5400d14041c0b8a30ede352603688b8b076..32efeaa52c019c115dec3090317cce8cdbcbc814 100644 (file)
@@ -256,7 +256,7 @@ HELP: polar>
 { $description "Converts an absolute value and argument (polar form) to a complex number." } ;
 
 HELP: [-1,1]?
-{ $values { "x" number } { "?" "a boolean" } }
+{ $values { "x" number } { "?" boolean } }
 { $description "Tests if " { $snippet "x" } " is a real number between -1 and 1, inclusive." } ;
 
 HELP: abs
@@ -286,7 +286,7 @@ HELP: gcd
 { $notes "If " { $snippet "d" } " is 1, then " { $snippet "a" } " is the inverse of " { $snippet "y" } " modulo " { $snippet "x" } "." } ;
 
 HELP: divisor?
-{ $values { "m" integer } { "n" integer } { "?" "a boolean" } }
+{ $values { "m" integer } { "n" integer } { "?" boolean } }
 { $description "Tests if " { $snippet "n" } " is a divisor of " { $snippet "m" } ". This is the same thing as asking if " { $snippet "m" } " is divisible by " { $snippet "n" } "." }
 { $notes "Returns t for both negative and positive divisors, as well as for trivial and non-trivial divisors." } ;
 
@@ -304,7 +304,7 @@ HELP: ^mod
 { $description "Outputs the result of computing " { $snippet "x^y mod n" } "." } ;
 
 HELP: ~
-{ $values { "x" real } { "y" real } { "epsilon" real } { "?" "a boolean" } }
+{ $values { "x" real } { "y" real } { "epsilon" real } { "?" boolean } }
 { $description "Tests if " { $snippet "x" } " and " { $snippet "y" } " are approximately equal to each other. There are three possible comparison tests, chosen based on the sign of " { $snippet "epsilon" } ":"
     { $list
         { { $snippet "epsilon" } " is zero: exact comparison." }
index fd6a72807f40c462472bf54c9a7afd62e00e27d5..309e1ca074e68f8db872ed7a9fcb3770eb462fdf 100644 (file)
@@ -1,4 +1,4 @@
-USING: help.markup help.syntax math math.order ;
+USING: help.markup help.syntax kernel math math.order ;
 IN: math.intervals
 
 ARTICLE: "math-intervals-new" "Creating intervals"
@@ -227,7 +227,7 @@ HELP: interval-log2
 { $description "Integer-valued Base-2 logarithm of an interval." } ;
 
 HELP: interval-intersect
-{ $values { "i1" interval } { "i2" interval } { "i3" "an " { $link interval  } " or " { $link f } } }
+{ $values { "i1" interval } { "i2" interval } { "i3" { $maybe interval } } }
 { $description "Outputs the set-theoretic intersection of " { $snippet "i1" } " and " { $snippet "i2" } ". If " { $snippet "i1" } " and " { $snippet "i2" } " do not intersect, outputs " { $link f } "." } ;
 
 HELP: interval-union
@@ -235,11 +235,11 @@ HELP: interval-union
 { $description "Outputs the smallest interval containing the set-theoretic union of " { $snippet "i1" } " and " { $snippet "i2" } " (the union itself may not be an interval)." } ;
 
 HELP: interval-subset?
-{ $values { "i1" interval } { "i2" interval } { "?" "a boolean" } }
+{ $values { "i1" interval } { "i2" interval } { "?" boolean } }
 { $description "Tests if every point of " { $snippet "i1" } " is contained in " { $snippet "i2" } "." } ;
 
 HELP: interval-contains?
-{ $values { "x" real } { "int" interval } { "?" "a boolean" } }
+{ $values { "x" real } { "int" interval } { "?" boolean } }
 { $description "Tests if " { $snippet "x" } " is contained in " { $snippet "int" } "." } ;
 
 HELP: interval-closure
@@ -335,7 +335,7 @@ HELP: assume<=
 { $description "Outputs the interval consisting of points from " { $snippet "i1" } " which are less or equal to all points in " { $snippet "i2" } "." } ;
 
 HELP: assume>
-{ $values { "i1" interval } { "i2" interval } { "i3" "an " { $link interval } " or " { $link f } } }
+{ $values { "i1" interval } { "i2" interval } { "i3" { $maybe interval } } }
 { $description "Outputs the interval consisting of points from " { $snippet "i1" } " which are greater than all points in " { $snippet "i2" } ". If the resulting interval is empty, outputs " { $link f } "." } ;
 
 HELP: assume>=
index ce00fcb495351ff49ce82ec9778724c9be92185a..05005c58b56b2360f248f1baefbfc4b400a7dad5 100644 (file)
@@ -1,4 +1,4 @@
-USING: help.markup help.syntax math sequences ;
+USING: help.markup help.syntax kernel math sequences ;
 IN: math.polynomials
 
 ARTICLE: "polynomials" "Polynomials"
@@ -31,7 +31,7 @@ HELP: powers
 { $examples { $example "USING: math.polynomials prettyprint ;" "4 2 powers ." "{ 1 2 4 8 }" } } ;
 
 HELP: p=
-{ $values { "p" "a polynomial" } { "q" "a polynomial" } { "?" "a boolean" } }
+{ $values { "p" "a polynomial" } { "q" "a polynomial" } { "?" boolean } }
 { $description "Tests if two polynomials are equal." }
 { $examples { $example "USING: math.polynomials prettyprint ;" "{ 0 1 } { 0 1 0 } p= ." "t" } } ;
 
index 3ba507b4fc22cd16f8331d5872342e2e0c1220c5..de99117860df6ab73e7dad1d0564cd5013619857 100644 (file)
@@ -6,7 +6,7 @@ IN: math.primes.lucas-lehmer
 HELP: lucas-lehmer
 { $values
     { "p" "a prime number" }
-    { "?" "a boolean" }
+    { "?" boolean }
 }
 { $description "Runs the Lucas-Lehmer test on the prime " { $snippet "p" } " and returns " { $link t } " if " { $snippet "(2 ^ p) - 1" } " is prime." }
 { $examples
index c374821dd6bd456e1ad6987b62b0bb6cac216c5d..7a35f041cb712bf845035e0ba353dd1a39025732 100644 (file)
@@ -6,7 +6,7 @@ IN: math.primes.miller-rabin
 HELP: miller-rabin
 { $values
     { "n" integer }
-    { "?" "a boolean" }
+    { "?" boolean }
 }
 { $description "Returns true if the number is a prime. Calls " { $link miller-rabin* } " with a default of 10 Miller-Rabin tests." } ;
 
@@ -15,7 +15,7 @@ HELP: miller-rabin
 HELP: miller-rabin*
 { $values
     { "n" integer } { "numtrials" integer }
-    { "?" "a boolean" }
+    { "?" boolean }
 }
 { $description "Performs " { $snippet "numtrials" } " trials of the Miller-Rabin probabilistic primality test algorithm and returns true if prime." } ;
 
index 938e9e7a4c2567f12b3060e7d2013dccd3fe677f..bca36883ec7ed7f1832933b793052b2d3c45d6c2 100644 (file)
@@ -1,4 +1,4 @@
-USING: help.markup help.syntax math sequences ;
+USING: help.markup help.syntax kernel math sequences ;
 IN: math.primes
 
 { next-prime prime? } related-words
@@ -8,21 +8,21 @@ HELP: next-prime
 { $description "Return the next prime number greater than " { $snippet "n" } "." } ;
 
 HELP: prime?
-{ $values { "n" "an integer" } { "?" "a boolean" } }
+{ $values { "n" integer } { "?" boolean } }
 { $description "Test if an integer is a prime number." } ;
 
 { nprimes primes-upto primes-between } related-words
 
 HELP: nprimes
-{ $values { "n" "a non-negative integer" } { "seq" "a sequence" } }
+{ $values { "n" "a non-negative integer" } { "seq" sequence } }
 { $description "Return a sequence containing the " { $snippet "n" } " first primes numbers." } ;
 
 HELP: primes-upto
-{ $values { "n" "an integer" } { "seq" "a sequence" } }
+{ $values { "n" integer } { "seq" sequence } }
 { $description "Return a sequence containing all the prime numbers smaller or equal to " { $snippet "n" } "." } ;
 
 HELP: primes-between
-{ $values { "low" "an integer" } { "high" "an integer" } { "seq" "a sequence" } }
+{ $values { "low" integer } { "high" integer } { "seq" sequence } }
 { $description "Return a sequence containing all the prime numbers between " { $snippet "low" } " and " { $snippet "high" } "." } ;
 
 HELP: find-relative-prime
index 231fde460aed660f2806a6929db0487929284b1e..e02f9ab90f9df72027b66263a963cae827af724d 100644 (file)
@@ -1,7 +1,6 @@
 ! Copyright (C) 2009 Doug Coleman.
 ! See http://factorcode.org/license.txt for BSD license.
-USING: combinators.short-circuit help.markup help.syntax kernel
-math math.functions math.primes random ;
+USING: help.markup help.syntax kernel math ;
 IN: math.primes.safe
 
 HELP: next-safe-prime
@@ -21,7 +20,7 @@ HELP: random-safe-prime
 HELP: safe-prime?
 { $values
     { "q" integer }
-    { "?" "a boolean" }
+    { "?" boolean }
 }
 { $description "Tests whether the number is a safe prime. A safe prime " { $snippet "p" } " must be prime, as must " { $snippet "(p - 1) / 2" } "." } ;
 
index 1ca6c2e58464135c2fe9cc749f68d3b2f62258fb..50d7c2a48373c21b1ea0f223f90a8144655c2bce 100644 (file)
@@ -1,4 +1,4 @@
-USING: help.markup help.syntax ;
+USING: help.markup help.syntax kernel ;
 IN: math.rectangles
 
 HELP: rect
@@ -39,11 +39,11 @@ HELP: rect-intersect
 { $description "Computes the intersection of two rectangles." } ;
 
 HELP: contains-rect?
-{ $values { "rect1" rect } { "rect2" rect } { "?" "a boolean" } }
+{ $values { "rect1" rect } { "rect2" rect } { "?" boolean } }
 { $description "Tests if two rectangles have a non-empty intersection." } ;
 
 HELP: contains-point?
-{ $values { "point" "a pair of integers" } { "rect" rect } { "?" "a boolean" } }
+{ $values { "point" "a pair of integers" } { "rect" rect } { "?" boolean } }
 { $description "Tests if a rectangle contains a point." } ;
 
 HELP: <zero-rect>
index 86faa76d8620a8a51f763fc6a3f7677c736a92c4..56a3f390b9b70db80d9a351a2eb87395202f4d36 100644 (file)
@@ -1,4 +1,5 @@
-USING: help.markup help.syntax math math.functions sequences ;
+USING: help.markup help.syntax kernel math math.functions
+sequences ;
 IN: math.vectors
 
 ARTICLE: "math-vectors-arithmetic" "Vector arithmetic"
@@ -376,7 +377,7 @@ HELP: hrshift
 { $description "Shifts the entire SIMD array to the right by " { $snippet "n" } " bytes, filling the vacated left-hand bits with zeroes. This word may only be used in a context where the compiler can statically infer that the input is a SIMD array." } ;
 
 HELP: vmerge
-{ $values { "u" "a sequence" } { "v" "a sequence" } { "w" "a sequence" } }
+{ $values { "u" sequence } { "v" sequence } { "w" sequence } }
 { $description "Creates a new sequence of the same type as and twice the length of " { $snippet "u" } " and " { $snippet "v" } " by interleaving the elements of " { $snippet "u" } " and " { $snippet "v" } "." }
 { $examples
 { $example """USING: kernel math.vectors prettyprint ;
@@ -386,7 +387,7 @@ HELP: vmerge
 } } ;
 
 HELP: (vmerge)
-{ $values { "u" "a sequence" } { "v" "a sequence" } { "h" "a sequence" } { "t" "a sequence" } }
+{ $values { "u" sequence } { "v" sequence } { "h" sequence } { "t" sequence } }
 { $description "Creates two new sequences of the same type and size as " { $snippet "u" } " and " { $snippet "v" } " by interleaving the elements of " { $snippet "u" } " and " { $snippet "v" } "." }
 { $notes "For hardware-supported SIMD vector types this word compiles to a single instruction per output value." }
 { $examples
@@ -398,7 +399,7 @@ HELP: (vmerge)
 } } ;
 
 HELP: (vmerge-head)
-{ $values { "u" "a sequence" } { "v" "a sequence" } { "h" "a sequence" } }
+{ $values { "u" sequence } { "v" sequence } { "h" sequence } }
 { $description "Creates a new sequence of the same type and size as " { $snippet "u" } " and " { $snippet "v" } " by interleaving the elements from the first half of " { $snippet "u" } " and " { $snippet "v" } "." }
 { $notes "For hardware-supported SIMD vector types this word compiles to a single instruction." }
 { $examples
@@ -409,7 +410,7 @@ HELP: (vmerge-head)
 } } ;
 
 HELP: (vmerge-tail)
-{ $values { "u" "a sequence" } { "v" "a sequence" } { "t" "a sequence" } }
+{ $values { "u" sequence } { "v" sequence } { "t" sequence } }
 { $description "Creates a new sequence of the same type and size as " { $snippet "u" } " and " { $snippet "v" } " by interleaving the elements from the tail half of " { $snippet "u" } " and " { $snippet "v" } "." }
 { $notes "For hardware-supported SIMD vector types this word compiles to a single instruction." }
 { $examples
@@ -550,7 +551,7 @@ HELP: v?
 { $notes "See " { $link "math-vectors-simd-logic" } " for notes on dealing with vector boolean inputs and results when using SIMD types." } ;
 
 HELP: vif
-{ $values { "mask" "a sequence of booleans" } { "true-quot" { $quotation ( -- vector ) } } { "false-quot" { $quotation ( -- vector ) } } { "result" "a sequence" } }
+{ $values { "mask" "a sequence of booleans" } { "true-quot" { $quotation ( -- vector ) } } { "false-quot" { $quotation ( -- vector ) } } { "result" sequence } }
 { $description "If all of the elements of " { $snippet "mask" } " are true, " { $snippet "true-quot" } " is called and its output value returned. If all of the elements of " { $snippet "mask" } " are false, " { $snippet "false-quot" } " is called and its output value returned. Otherwise, both quotations are called and " { $snippet "mask" } " is used to select elements from each output as with " { $link v? } "." }
 { $notes "See " { $link "math-vectors-simd-logic" } " for notes on dealing with vector boolean inputs and results when using SIMD types."
 $nl
@@ -559,17 +560,17 @@ $nl
 { v? vif } related-words
 
 HELP: vany?
-{ $values { "v" "a sequence of booleans" } { "?" "a boolean" } }
+{ $values { "v" "a sequence of booleans" } { "?" boolean } }
 { $description "Returns true if any element of " { $snippet "v" } " is true." }
 { $notes "See " { $link "math-vectors-simd-logic" } " for notes on dealing with vector boolean inputs when using SIMD types." } ;
 
 HELP: vall?
-{ $values { "v" "a sequence of booleans" } { "?" "a boolean" } }
+{ $values { "v" "a sequence of booleans" } { "?" boolean } }
 { $description "Returns true if every element of " { $snippet "v" } " is true." }
 { $notes "See " { $link "math-vectors-simd-logic" } " for notes on dealing with vector boolean inputs when using SIMD types." } ;
 
 HELP: vnone?
-{ $values { "v" "a sequence of booleans" } { "?" "a boolean" } }
+{ $values { "v" "a sequence of booleans" } { "?" boolean } }
 { $description "Returns true if every element of " { $snippet "v" } " is false." }
 { $notes "See " { $link "math-vectors-simd-logic" } " for notes on dealing with vector boolean inputs when using SIMD types." } ;
 
index 8b43c56f6d2ae30f0ee0eb272deb6aa0503e449d..159148f46cae74af212ab1e319756585ee9c4a38 100644 (file)
@@ -11,7 +11,7 @@ HELP: gl-vendor-version
 { $description "Wrapper for " { $snippet "GL_VERSION glGetString" } " that returns only the vendor-specific information from the version string." } ;
 
 HELP: has-gl-version?
-{ $values { "version" "A version string" } { "?" "A boolean value" } }
+{ $values { "version" "A version string" } { "?" boolean } }
 { $description "Compares the version string returned by " { $link gl-version } " to " { $snippet "version" } ". Returns true if the implementation version meets or exceeds " { $snippet "version" } "." } ;
 
 HELP: require-gl-version
@@ -27,7 +27,7 @@ HELP: glsl-vendor-version
 { $description "Wrapper for " { $snippet "GL_SHADING_LANGUAGE_VERSION glGetString" } " that returns only the vendor-specific information from the version string." } ;
 
 HELP: has-glsl-version?
-{ $values { "version" "A version string" } { "?" "A boolean value" } }
+{ $values { "version" "A version string" } { "?" boolean } }
 { $description "Compares the version string returned by " { $link glsl-version } " to " { $snippet "version" } ". Returns true if the implementation version meets or exceeds " { $snippet "version" } "." } ;
 
 HELP: require-glsl-version
@@ -39,7 +39,7 @@ HELP: gl-extensions
 { $description "Wrapper for " { $snippet "GL_EXTENSIONS glGetString" } " that returns a sequence of extension names supported by the OpenGL implementation." } ;
 
 HELP: has-gl-extensions?
-{ $values { "extensions" "A sequence of extension name strings" } { "?" "A boolean value" } }
+{ $values { "extensions" "A sequence of extension name strings" } { "?" boolean } }
 { $description "Returns true if the set of " { $snippet "extensions" } " is a subset of the implementation-supported extensions returned by " { $link gl-extensions } ". Elements of " { $snippet "extensions" } " can be sequences, in which case true will be returned if any one of the extensions in the subsequence are available." }
 { $examples "Testing for framebuffer object and pixel buffer support:"
     { $code """{
@@ -49,7 +49,7 @@ HELP: has-gl-extensions?
 } ;
 
 HELP: has-gl-version-or-extensions?
-{ $values { "version" "A version string" } { "extensions" "A sequence of extension name strings" } { "?" "a boolean" } }
+{ $values { "version" "A version string" } { "extensions" "A sequence of extension name strings" } { "?" boolean } }
 { $description "Returns true if either " { $link has-gl-version? } " or " { $link has-gl-extensions? } " returns true for " { $snippet "version" } " or " { $snippet "extensions" } ", respectively. Intended for use when required OpenGL functionality can be verified either by a minimum version or a set of equivalent extensions." } ;
 
 HELP: require-gl-extensions
index 6efa63d04e7c9bc549e8f504aebdae1fef776b06..74f1b79e1025043fa834d15df7a15a3ad9160311 100644 (file)
@@ -1,5 +1,4 @@
-USING: help.markup help.syntax io kernel math quotations
-opengl.gl multiline assocs ;
+USING: help.markup help.syntax math opengl.gl quotations ;
 IN: opengl.framebuffers
 
 HELP: gen-framebuffer
@@ -29,7 +28,7 @@ HELP: check-framebuffer
 { $description "Checks the framebuffer currently bound by " { $link glBindFramebuffer } " or " { $link with-framebuffer } " with " { $link framebuffer-incomplete? } ", and throws a descriptive error if the framebuffer is incomplete." } ;
 
 HELP: with-framebuffer
-{ $values { "id" "The id of a framebuffer object." } { "quot" "a quotation" } }
+{ $values { "id" "The id of a framebuffer object." } { "quot" quotation } }
 { $description "Binds framebuffer " { $snippet "id" } " for drawing in the dynamic extent of " { $snippet "quot" } ", restoring the window framebuffer when finished." } ;
 
 ABOUT: "gl-utilities"
index c3e4d045ef54dd58ca57aec286c56e9fcaff4572..ac938f3a48d014cd69ca929b316a530f89443271 100644 (file)
@@ -40,7 +40,7 @@ HELP: <fragment-shader>
 { $description "Tries to compile the given GLSL source into a fragment shader object. Equivalent to " { $snippet "GL_FRAGMENT_SHADER <gl-shader>" } "." } ;
 
 HELP: gl-shader-ok?
-{ $values { "shader" "A " { $link gl-shader } " object" } { "?" "a boolean" } }
+{ $values { "shader" "A " { $link gl-shader } " object" } { "?" boolean } }
 { $description "Returns a boolean value indicating whether the given shader object compiled successfully. Compilation errors and warnings are available in the shader's info log, which can be gotten using " { $link gl-shader-info-log } "." } ;
 
 HELP: check-gl-shader
@@ -79,7 +79,7 @@ HELP: <simple-gl-program>
 { <gl-program> <simple-gl-program> } related-words
 
 HELP: gl-program-ok?
-{ $values { "program" "A " { $link gl-program } " object" } { "?" "a boolean" } }
+{ $values { "program" "A " { $link gl-program } " object" } { "?" boolean } }
 { $description "Returns a boolean value indicating whether the given program object linked successfully. Link errors and warnings are available in the program's info log, which can be gotten using " { $link gl-program-info-log } "." } ;
 
 HELP: check-gl-program
index 31d4961b98deef7e7c2c421118b182b2307ea327..fe90a5ffe5bcca4a92684d34100e8762b1ece167 100644 (file)
@@ -1,6 +1,6 @@
 ! Copyright (C) 2009 Chris Double.
 ! See http://factorcode.org/license.txt for BSD license.
-USING: help.syntax help.markup peg peg.search ;
+USING: help.syntax help.markup peg peg.search words ;
 IN: peg.ebnf
 
 HELP: <EBNF
@@ -40,7 +40,7 @@ HELP: [EBNF
 
 HELP: EBNF:
 { $syntax "EBNF: word ...ebnf... ;EBNF" }
-{ $values { "word" "a word" } { "...ebnf..." "EBNF DSL text" } }
+{ $values { "word" word } { "...ebnf..." "EBNF DSL text" } }
 { $description
     "Defines a word that when called will parse a string using the syntax "
     "defined with the EBNF DSL. The word has stack effect "
index 7ffd458fce6745fb49f101cdcc7de93c84afc81d..3eae7c776e4d43800b010eb49cea1ba4e6741a94 100644 (file)
@@ -1,7 +1,7 @@
 ! Copyright (C) 2008 Chris Double, Doug Coleman.
 ! See http://factorcode.org/license.txt for BSD license.
-USING: help.markup help.syntax peg peg.parsers.private
-unicode.categories ;
+USING: help.markup help.syntax kernel math sequences
+unicode.categories strings ;
 IN: peg.parsers
 
 HELP: 1token
@@ -16,9 +16,9 @@ HELP: 1token
 
 HELP: (list-of)
 { $values
-    { "items" "a sequence" }
+    { "items" sequence }
     { "separator" "a parser" }
-    { "repeat1?" "a boolean" }
+    { "repeat1?" boolean }
     { "parser" "a parser" }
 } { $description
     "Returns a parser that returns a list of items separated by the separator parser.  Does not hide the separators."
@@ -26,7 +26,7 @@ HELP: (list-of)
 
 HELP: list-of
 { $values
-    { "items" "a sequence" }
+    { "items" sequence }
     { "separator" "a parser" }
     { "parser" "a parser" }
 } { $description
@@ -36,10 +36,10 @@ HELP: list-of
     { $example "USING: peg peg.parsers prettyprint ;" "\"a\" \"a\" token \",\" token list-of parse  ." "V{ \"a\" }" }
     { $example "USING: peg peg.parsers prettyprint ;" "\"a,a,a,a\" \"a\" token \",\" token list-of parse ." "V{ \"a\" \"a\" \"a\" \"a\" }" }
 } { $see-also list-of-many } ;
-    
+
 HELP: list-of-many
 { $values
-    { "items" "a sequence" }
+    { "items" sequence }
     { "separator" "a parser" }
     { "parser" "a parser" }
 } { $description
@@ -67,7 +67,7 @@ HELP: any-char
 HELP: exactly-n
 { $values
     { "parser" "a parser" }
-    { "n" "an integer" }
+    { "n" integer }
     { "parser'" "a parser" }
 } { $description
     "Returns a parser that matches an exact repetition of the input parser."
@@ -79,7 +79,7 @@ HELP: exactly-n
 HELP: at-least-n
 { $values
     { "parser" "a parser" }
-    { "n" "an integer" }
+    { "n" integer }
     { "parser'" "a parser" }
 } { $description
     "Returns a parser that matches n or more repetitions of the input parser."
@@ -92,7 +92,7 @@ HELP: at-least-n
 HELP: at-most-n
 { $values
     { "parser" "a parser" }
-    { "n" "an integer" }
+    { "n" integer }
     { "parser'" "a parser" }
 } { $description
     "Returns a parser that matches n or fewer repetitions of the input parser."
@@ -104,8 +104,8 @@ HELP: at-most-n
 HELP: from-m-to-n
 { $values
     { "parser" "a parser" }
-    { "m" "an integer" }
-    { "n" "an integer" }
+    { "m" integer }
+    { "n" integer }
     { "parser'" "a parser" }
 } { $description
     "Returns a parser that matches between and including m to n repetitions of the input parser."
@@ -130,8 +130,8 @@ HELP: pack
 HELP: surrounded-by
 { $values
     { "parser" "a parser" }
-    { "begin" "a string" }
-    { "end" "a string" }
+    { "begin" string }
+    { "end" string }
     { "parser'" "a parser" }
 } { $description
     "Calls token on begin and end to make them into string parsers.  Returns a parser that parses the begin, body, and end parsers in order.  The begin and end parsers are hidden."
@@ -162,7 +162,7 @@ HELP: 'string'
 
 HELP: range-pattern
 { $values
-    { "pattern" "a string" }
+    { "pattern" string }
     { "parser" "a parser" }
 } { $description
 "Returns a parser that matches a single character based on the set "
index ee2fc78bb479e8cc5546fd19b7a06af143501e61..761c66fdee75f1b19c39f908c97e43cf4ad095e7 100644 (file)
@@ -1,13 +1,13 @@
 ! Copyright (C) 2007 Chris Double.\r
 ! See http://factorcode.org/license.txt for BSD license.\r
-USING: help.markup help.syntax ;\r
+USING: help.markup help.syntax kernel quotations strings words ;\r
 IN: peg\r
 \r
 HELP: parse\r
 { $values \r
-  { "input" "a string" } \r
-  { "parser" "a parser" } \r
-  { "ast" "an object" } \r
+  { "input" string }\r
+  { "parser" parser }\r
+  { "ast" object }\r
 }\r
 { $description \r
     "Given the input string, parse it using the given parser. The result is the abstract "\r
@@ -16,8 +16,8 @@ HELP: parse
 \r
 HELP: compile\r
 { $values \r
-  { "parser" "a parser" } \r
-  { "word" "a word" } \r
+  { "parser" parser }\r
+  { "word" word }\r
 }\r
 { $description \r
     "Compile the parser to a word. The word will have stack effect ( -- ast )."\r
@@ -26,35 +26,35 @@ HELP: compile
 \r
 HELP: token\r
 { $values \r
-  { "string" "a string" } \r
-  { "parser" "a parser" } \r
+  { "string" string }\r
+  { "parser" parser }\r
 }\r
 { $description \r
     "Returns a parser that matches the given string." } ;\r
 \r
 HELP: satisfy\r
-{ $values \r
-  { "quot" "a quotation" } \r
-  { "parser" "a parser" } \r
+{ $values\r
+  { "quot" quotation }\r
+  { "parser" parser }\r
 }\r
 { $description \r
     "Returns a parser that calls the quotation on the first character of the input string, "\r
     "succeeding if that quotation returns true. The AST is the character from the string." } ;\r
 \r
 HELP: range\r
-{ $values \r
-  { "min" "a character" } \r
-  { "max" "a character" } \r
-  { "parser" "a parser" } \r
+{ $values\r
+  { "min" "a character" }\r
+  { "max" "a character" }\r
+  { "parser" parser }\r
 }\r
-{ $description \r
+{ $description\r
     "Returns a parser that matches a single character that lies within the range of characters given, inclusive." }\r
 { $examples { $code ": digit ( -- parser ) CHAR: 0 CHAR: 9 range ;" } } ;\r
 \r
 HELP: seq\r
-{ $values \r
-  { "seq" "a sequence of parsers" } \r
-  { "parser" "a parser" } \r
+{ $values\r
+  { "seq" "a sequence of parsers" }\r
+  { "parser" parser }\r
 }\r
 { $description \r
     "Returns a parser that calls all parsers in the given sequence, in order. The parser succeeds if "\r
@@ -64,7 +64,7 @@ HELP: seq
 HELP: choice\r
 { $values \r
   { "seq" "a sequence of parsers" } \r
-  { "parser" "a parser" } \r
+  { "parser" parser } \r
 }\r
 { $description \r
     "Returns a parser that will try all the parsers in the sequence, in order, until one succeeds. "\r
@@ -72,7 +72,7 @@ HELP: choice
 \r
 HELP: repeat0\r
 { $values \r
-  { "parser" "a parser" } \r
+  { "parser" parser } \r
 }\r
 { $description \r
     "Returns a parser that parses 0 or more instances of the 'p1' parser. The AST produced is "\r
@@ -81,7 +81,7 @@ HELP: repeat0
 \r
 HELP: repeat1\r
 { $values \r
-  { "parser" "a parser" } \r
+  { "parser" parser } \r
 }\r
 { $description \r
     "Returns a parser that parses 1 or more instances of the 'p1' parser. The AST produced is "\r
@@ -89,7 +89,7 @@ HELP: repeat1
 \r
 HELP: optional\r
 { $values \r
-  { "parser" "a parser" } \r
+  { "parser" parser } \r
 }\r
 { $description \r
     "Returns a parser that parses 0 or 1 instances of the 'p1' parser. The AST produced is "\r
@@ -97,7 +97,7 @@ HELP: optional
 \r
 HELP: semantic\r
 { $values \r
-  { "parser" "a parser" } \r
+  { "parser" parser } \r
   { "quot" { $quotation ( object -- ? ) } } \r
 }\r
 { $description \r
@@ -109,7 +109,7 @@ HELP: semantic
 \r
 HELP: ensure\r
 { $values \r
-  { "parser" "a parser" } \r
+  { "parser" parser } \r
 }\r
 { $description \r
     "Returns a parser that succeeds if the 'p1' parser succeeds but does not add anything to the "\r
@@ -119,7 +119,7 @@ HELP: ensure
 \r
 HELP: ensure-not\r
 { $values \r
-  { "parser" "a parser" } \r
+  { "parser" parser } \r
 }\r
 { $description \r
     "Returns a parser that succeeds if the 'p1' parser fails but does not add anything to the "\r
@@ -129,7 +129,7 @@ HELP: ensure-not
 \r
 HELP: action\r
 { $values \r
-  { "parser" "a parser" } \r
+  { "parser" parser } \r
   { "quot" { $quotation ( ast -- ast ) } } \r
 }\r
 { $description \r
@@ -141,7 +141,7 @@ HELP: action
 \r
 HELP: sp\r
 { $values \r
-  { "parser" "a parser" } \r
+  { "parser" parser } \r
 }\r
 { $description \r
     "Returns a parser that calls the original parser 'p1' after stripping any whitespace "\r
@@ -149,7 +149,7 @@ HELP: sp
 \r
 HELP: hide\r
 { $values \r
-  { "parser" "a parser" } \r
+  { "parser" parser } \r
 }\r
 { $description \r
     "Returns a parser that succeeds if the original parser succeeds, but does not " \r
@@ -158,8 +158,8 @@ HELP: hide
 \r
 HELP: delay\r
 { $values \r
-  { "quot" "a quotation" } \r
-  { "parser" "a parser" } \r
+  { "quot" quotation } \r
+  { "parser" parser } \r
 }\r
 { $description \r
     "Delays the construction of a parser until it is actually required to parse. This " \r
@@ -170,8 +170,8 @@ HELP: delay
 \r
 HELP: box\r
 { $values \r
-  { "quot" "a quotation" } \r
-  { "parser" "a parser" } \r
+  { "quot" quotation } \r
+  { "parser" parser } \r
 }\r
 { $description \r
     "Delays the construction of a parser until the parser is compiled. The quotation "\r
index 565601ea11facb93c200a8265e424fb53d31f7e9..6762373744ef34eef49ba0269ec3b97a2b075045 100644 (file)
@@ -1,11 +1,11 @@
 ! Copyright (C) 2006 Chris Double.
 ! See http://factorcode.org/license.txt for BSD license.
-USING: help.syntax help.markup peg ;
+USING: help.markup help.syntax kernel peg sequences strings ;
 IN: peg.search
 
 HELP: tree-write
 { $values
-  { "object" "an object" } }
+  { "object" object } }
 { $description
     "Write the object to the standard output stream, unless "
     "it is an array, in which case recurse through the array "
@@ -14,9 +14,9 @@ HELP: tree-write
 
 HELP: search
 { $values
-  { "string" "a string" }
+  { "string" string }
   { "parser" "a peg based parser" }
-  { "seq"    "a sequence" }
+  { "seq"    sequence }
 }
 { $description
     "Returns a sequence containing the parse results of all substrings "
@@ -30,9 +30,9 @@ HELP: search
 
 HELP: replace
 { $values
-  { "string" "a string" }
+  { "string" string }
   { "parser" "a peg based parser" }
-  { "result"    "a string" }
+  { "result" string }
 }
 { $description
     "Returns a copy of the original string but with all substrings that "
index 31422f23b9c894fec7b493a474db310fb30f10b2..3da6578d54f07f379ec3629af97b7221f0d6b1b0 100644 (file)
@@ -10,7 +10,7 @@ HELP: <singleton-heap>
 { $description "Creates a new persistent heap consisting of one object with the given priority." } ;
 
 HELP: pheap-empty?
-{ $values { "heap" "a persistent heap" } { "?" "a boolean" } }
+{ $values { "heap" "a persistent heap" } { "?" boolean } }
 { $description "Returns true if this is an empty persistent heap." } ;
 
 HELP: pheap-peek
index 537dfe79ce9983922620ec4131cd2985587732d2..9524ce233eb00f664ae85843005c8a3e15b42faa 100644 (file)
@@ -2,7 +2,7 @@ IN: porter-stemmer
 USING: help.markup help.syntax ;
 
 HELP: step1a
-{ $values { "str" "a string" } { "newstr" "a new string" } }
+{ $values { "str" string } { "newstr" "a new string" } }
 { $description "Gets rid of plurals." }
 { $examples
     { $table
@@ -16,7 +16,7 @@ HELP: step1a
 } ;
 
 HELP: step1b
-{ $values { "str" "a string" } { "newstr" "a new string" } }
+{ $values { "str" string } { "newstr" "a new string" } }
 { $description "Gets rid of \"-ed\" and \"-ing\" suffixes." }
 { $examples
     { $table
@@ -34,23 +34,23 @@ HELP: step1b
 } ;
 
 HELP: step1c
-{ $values { "str" "a string" } { "newstr" "a new string" } }
+{ $values { "str" string } { "newstr" "a new string" } }
 { $description "Turns a terminal y to i when there is another vowel in the stem." } ;
 
 HELP: step2
-{ $values { "str" "a string" } { "newstr" "a new string" } }
+{ $values { "str" string } { "newstr" "a new string" } }
 { $description "Maps double suffices to single ones. so -ization maps to -ize etc. note that the string before the suffix must give positive " { $link consonant-seq } "." } ;
 
 HELP: step3
-{ $values { "str" "a string" } { "newstr" "a new string" } }
+{ $values { "str" string } { "newstr" "a new string" } }
 { $description "Deals with -c-, -full, -ness, etc. Similar strategy to " { $link step2 } "." } ;
 
 HELP: step5
-{ $values { "str" "a string" } { "newstr" "a new string" } }
+{ $values { "str" string } { "newstr" "a new string" } }
 { $description "Removes a final -e and changes a final -ll to -l if " { $link consonant-seq } " is greater than 1," } ;
 
 HELP: stem
-{ $values { "str" "a string" } { "newstr" "a new string" } }
+{ $values { "str" string } { "newstr" "a new string" } }
 { $description "Applies the Porter stemming algorithm to the input string." } ;
 
 ARTICLE: "porter-stemmer" "Porter stemming algorithm"
index 324a4d26884f741793ca84a7dd4789d7fa6f8c45..250fbe61b0043f3d479d4260ea668ababc9de233 100644 (file)
@@ -1,12 +1,11 @@
-USING: help.markup help.syntax io kernel
-prettyprint.config prettyprint.sections prettyprint.custom
-words strings ;
+USING: help.markup help.syntax kernel prettyprint.config
+prettyprint.custom sequences strings words ;
 IN: prettyprint.backend
 
 ABOUT: "prettyprint-extension"
 
 HELP: pprint-word
-{ $values { "word" "a word" } }
+{ $values { "word" word } }
 { $description "Adds a text section for the word. Unlike the " { $link word } " method of " { $link pprint* } ", this does not add a " { $link POSTPONE: POSTPONE: } " prefix to parsing words." }
 $prettyprinting-note ;
 
@@ -28,21 +27,21 @@ HELP: pprint-string
 $prettyprinting-note ;
 
 HELP: nesting-limit?
-{ $values { "?" "a boolean" } }
+{ $values { "?" boolean } }
 { $description "Tests if the " { $link nesting-limit } " has been reached." }
 $prettyprinting-note ;
 
 HELP: check-recursion
-{ $values { "obj" "an object" } { "quot" { $quotation ( obj -- ) } } }
+{ $values { "obj" object } { "quot" { $quotation ( obj -- ) } } }
 { $description "If the object is already being printed, that is, if the prettyprinter has encountered a cycle in the object graph, or if the maximum nesting depth has been reached, outputs a dummy string. Otherwise applies the quotation to the object." }
 $prettyprinting-note ;
 
 HELP: do-length-limit
-{ $values { "seq" "a sequence" } { "trimmed" "a trimmed sequence" } { "n/f" "an integer or " { $link f } } }
+{ $values { "seq" sequence } { "trimmed" "a trimmed sequence" } { "n/f" "an integer or " { $link f } } }
 { $description "If the " { $link length-limit } " is set and the sequence length exceeds this limit, trims the sequence and outputs a the number of elements which were chopped off the end. Otherwise outputs " { $link f } "." }
 $prettyprinting-note ;
 
 HELP: pprint-elements
-{ $values { "seq" "a sequence" } }
+{ $values { "seq" sequence } }
 { $description "Prettyprints the elements of a sequence, trimming the sequence to " { $link length-limit } " if necessary." }
 $prettyprinting-note ;
index 33e1857260e0d15967fe570ee98c842a888744d1..299c72f0a49d27c620fee203158f3431b95da4c3 100644 (file)
@@ -1,7 +1,6 @@
-USING: prettyprint.backend prettyprint.config prettyprint.custom
-prettyprint.sections help.markup help.syntax
-io kernel words definitions quotations strings generic classes
-prettyprint.private ;
+USING: help.markup help.syntax io kernel math
+prettyprint.backend prettyprint.config prettyprint.custom
+prettyprint.private prettyprint.sections sequences ;
 IN: prettyprint
 
 ARTICLE: "prettyprint-numbers" "Prettyprinting numbers"
@@ -222,11 +221,11 @@ HELP: short.
 { $description "Prettyprints an object to " { $link output-stream } " with a trailing line break. This word rebinds printer control variables to enforce “shorter” output." } ;
 
 HELP: .b
-{ $values { "n" "an integer" } }
+{ $values { "n" integer } }
 { $description "Outputs an integer in binary." } ;
 
 HELP: .o
-{ $values { "n" "an integer" } }
+{ $values { "n" integer } }
 { $description "Outputs an integer in octal." } ;
 
 HELP: .h
@@ -234,7 +233,7 @@ HELP: .h
 { $description "Outputs an integer or floating-point value in hexadecimal." } ;
 
 HELP: stack.
-{ $values { "seq" "a sequence" } }
+{ $values { "seq" sequence } }
 { $description "Prints a the elements of the sequence, one per line." }
 { $notes "This word is used in the implementation of " { $link .s } " and " { $link .r } "." } ;
 
index ef90f9b9ef22d4757d9c0cb0bd78d927380d2430..b645fc0e8ae8da84b717cd8a1a5d1207f170bdeb 100644 (file)
@@ -1,6 +1,5 @@
-USING: prettyprint io kernel help.markup help.syntax
-prettyprint.config words hashtables math
-strings definitions quotations ;
+USING: hashtables help.markup help.syntax io kernel math
+prettyprint.config quotations strings ;
 IN: prettyprint.sections
 
 HELP: position
@@ -10,7 +9,7 @@ HELP: recursion-check
 { $var-description "The current nesting of collections being output by the prettyprinter, used to detect circularity and prevent infinite recursion." } ;
 
 HELP: line-limit?
-{ $values { "?" "a boolean" } }
+{ $values { "?" boolean } }
 { $description "Tests if the line number limit has been reached, and thus if prettyprinting should stop." } ;
 
 HELP: do-indent
@@ -29,7 +28,7 @@ HELP: hard
 { soft hard } related-words
 
 HELP: section-fits?
-{ $values { "section" section } { "?" "a boolean" } }
+{ $values { "section" section } { "?" boolean } }
 { $contract "Tests if a section fits in the space that remains on the current line." } ;
 
 HELP: short-section
@@ -41,20 +40,20 @@ HELP: long-section
 { $contract "Prints a section which spans multiple lines. This should use a layout strategy maximizing readability and minimizing line length." } ;
 
 HELP: indent-section?
-{ $values { "section" section } { "?" "a boolean" } }
+{ $values { "section" section } { "?" boolean } }
 { $contract "Outputs a boolean indicating if the indent level should be increased when printing this section as a " { $link long-section } ". Default implementation outputs " { $link f } "." } ;
 
 HELP: unindent-first-line?
-{ $values { "section" section } { "?" "a boolean" } }
+{ $values { "section" section } { "?" boolean } }
 { $contract "Outputs a boolean indicating if the indent level should only be increased for lines after the first line when printing this section as a " { $link long-section } ". Default implementation outputs " { $link f } "." }
 { $notes "This is used to format " { $link colon } " sections because of the colon definition formatting convention." } ;
 
 HELP: newline-after?
-{ $values { "section" section } { "?" "a boolean" } }
+{ $values { "section" section } { "?" boolean } }
 { $contract "Outputs a boolean indicating if a newline should be output after printing this section as a " { $link long-section } ". Default implementation outputs " { $link f } "." } ;
 
 HELP: short-section?
-{ $values { "section" section } { "?" "a boolean" } }
+{ $values { "section" section } { "?" boolean } }
 { $contract "Tests if a section should be output as a " { $link short-section } ". The default implementation calls " { $link section-fits? } " but this behavior can be customized." } ;
 
 HELP: section
@@ -152,7 +151,7 @@ HELP: do-break
 { $description "Prints a break section as per the policy outlined in " { $link line-break } "." } ;
 
 HELP: empty-block?
-{ $values { "block" block } { "?" "a boolean" } }
+{ $values { "block" block } { "?" boolean } }
 { $description "Tests if the block has no child sections." } ;
 
 HELP: if-nonempty
@@ -184,7 +183,7 @@ HELP: inset
 { $class-description "A " { $link block } " section which indents every line when printed as a " { $link long-section } "." } ;
 
 HELP: <inset
-{ $values { "narrow?" "a boolean" } }
+{ $values { "narrow?" boolean } }
 { $description "Begins an " { $link inset } " section. When printed as a " { $link long-section } ", the output format is determined by the " { $snippet "narrow?" } " flag. If it is " { $link f } ", then longer lines are favored, wrapping at the " { $link margin } ". Otherwise, every child section is printed on its own line." }
 { $examples
     "Compare the output of printing a long quotation versus a hashtable. Quotations are printed with " { $snippet "narrow?" } " set to " { $link f } ", and hashtables are printed with " { $snippet "narrow?" } " set to " { $link t } "."
index 7bfb77410f90ed43c3ebbfcecaa52f0a8b6af777..59104cb5b6b009c944f54d86b14776d1e9c99342 100644 (file)
@@ -1,6 +1,6 @@
 ! Copyright (C) 2009 Keith Lazuka.
 ! See http://factorcode.org/license.txt for BSD license.
-USING: help.markup help.syntax kernel words ;
+USING: help.markup help.syntax kernel strings words ;
 IN: prettyprint.stylesheet
 
 HELP: effect-style
@@ -12,7 +12,7 @@ HELP: effect-style
 
 HELP: string-style
 { $values
-    { "str" "a string" }
+    { "str" string }
     { "style" "a style assoc" }
 }
 { $description "The stylesheet for string literals" } ;
@@ -26,7 +26,7 @@ HELP: vocab-style
 
 HELP: word-style
 { $values
-    { "word" "a word" }
+    { "word" word }
     { "style" "a style assoc" }
 }
 { $description "The stylesheet for word names" } ;
index 6777e1be1a5f9ea771ae843da336449f2d950915..5a6598f035c6fa7744c404cdc903302c496e512e 100644 (file)
@@ -1,4 +1,5 @@
-USING: help.markup help.syntax math kernel sequences arrays ;
+USING: arrays help.markup help.syntax kernel math quotations
+sequences ;
 IN: random
 
 HELP: seed-random
@@ -14,7 +15,7 @@ HELP: random-32*
 { $description "Generates a random 32-bit unsigned integer." } ;
 
 HELP: random-bytes*
-{ $values { "n" "an integer" } { "obj" "a random number generator" } { "byte-array" "a sequence of random bytes" } }
+{ $values { "n" integer } { "obj" "a random number generator" } { "byte-array" "a sequence of random bytes" } }
 { $description "Generates a byte-array of random bytes." } ;
 
 HELP: random
@@ -36,7 +37,7 @@ HELP: random-32
 { $description "Outputs 32 random bits. This word is more efficient than calling " { $link random } " because no scaling is done on the output." } ;
 
 HELP: random-bytes
-{ $values { "n" "an integer" } { "byte-array" "a random integer" } }
+{ $values { "n" integer } { "byte-array" "a random integer" } }
 { $description "Outputs an integer with n bytes worth of bits." }
 { $examples 
     { $unchecked-example "USING: prettyprint random ;"
@@ -86,15 +87,15 @@ HELP: random-bits*
 { $description "Returns an integer exactly " { $snippet "numbits" } " in length, with the topmost bit set to one." } ;
 
 HELP: with-random
-{ $values { "obj" "a random number generator" } { "quot" "a quotation" } }
+{ $values { "obj" "a random number generator" } { "quot" quotation } }
 { $description "Calls the quotation with the random number generator in a dynamic variable.  All random numbers will be generated using this random number generator." } ;
 
 HELP: with-secure-random
-{ $values { "quot" "a quotation" } }
+{ $values { "quot" quotation } }
 { $description "Calls the quotation with the secure random number generator in a dynamic variable.  All random numbers will be generated using this random number generator." } ;
 
 HELP: with-system-random
-{ $values { "quot" "a quotation" } }
+{ $values { "quot" quotation } }
 { $description "Calls the quotation with the system's random number generator in a dynamic variable.  All random numbers will be generated using this random number generator." } ;
 
 { with-random with-secure-random with-system-random } related-words
index 54ba7db54088464f7a17f23b0ac6850a2d8196a1..aad796eabc445d4b5a34d0079be2ea80f0c07505 100644 (file)
@@ -210,7 +210,7 @@ HELP: regexp
 { $class-description "The class of regular expressions. To construct these, see " { $link "regexp-construction" } "." } ;
 
 HELP: matches?
-{ $values { "string" string } { "regexp" regexp } { "?" "a boolean" } }
+{ $values { "string" string } { "regexp" regexp } { "?" boolean } }
 { $description "Tests if the string as a whole matches the given regular expression." } ;
 
 HELP: all-matching-slices
@@ -252,5 +252,5 @@ HELP: first-match
 { $description "Finds the first match of the regular expression in the string, and returns it as a slice. If there is no match, then " { $link f } " is returned." } ;
 
 HELP: re-contains?
-{ $values { "string" string } { "regexp" regexp } { "?" "a boolean" } }
+{ $values { "string" string } { "regexp" regexp } { "?" boolean } }
 { $description "Determines whether the string has a substring which matches the regular expression given." } ;
index d872be0ca603a82f7d938ce22ee1068499f579d5..e3134e39fc9705c507563e4231d568d00153532c 100644 (file)
@@ -1,4 +1,5 @@
-USING: help.markup help.syntax strings definitions generic words classes ;
+USING: classes definitions generic help.markup help.syntax
+sequences strings words ;
 FROM: prettyprint.sections => with-pprint ;
 IN: see
 
@@ -42,7 +43,7 @@ HELP: definer
 { $notes "This word is used in the implementation of " { $link see } "." } ;
 
 HELP: definition
-{ $values { "defspec" "a definition specifier" } { "seq" "a sequence" } }
+{ $values { "defspec" "a definition specifier" } { "seq" sequence } }
 { $contract "Outputs the body of a definition." }
 { $examples
     { $example "USING: definitions math prettyprint ;" "\\ sq definition ." "[ dup * ]" }
@@ -62,4 +63,4 @@ $nl
     synopsis*
 } ;
 
-ABOUT: "see"
\ No newline at end of file
+ABOUT: "see"
index 5f75f0b237bd8970f24775adc24fe61368c3c521..d2661d6d41451554e321ade508aac82f4e4c9a1d 100644 (file)
@@ -26,7 +26,7 @@ HELP: deep-find
 { $see-also find } ;
 
 HELP: deep-any?
-{ $values { "obj" object } { "quot" { $quotation ( ... elt -- ... ? ) } } { "?" "a boolean" } }
+{ $values { "obj" object } { "quot" { $quotation ( ... elt -- ... ? ) } } { "?" boolean } }
 { $description "Tests whether the given object or any subnode satisfies the given quotation." }
 { $see-also any? } ;
 
index 620b3759a261d855d62a6fc8c81429631570915d..3158cfd9a55abdde01ccf521e204febae7f679e3 100644 (file)
@@ -1,11 +1,5 @@
-USING: help.syntax help.markup kernel sequences words io
-effects classes math combinators
-stack-checker.backend
-stack-checker.branches
-stack-checker.errors
-stack-checker.transforms
-stack-checker.state
-continuations ;
+USING: classes continuations effects help.markup help.syntax io
+kernel quotations sequences stack-checker.errors ;
 IN: stack-checker
 
 ARTICLE: "inference-simple" "Straight-line stack effects"
@@ -160,12 +154,12 @@ HELP: inference-error
 } ;
 
 HELP: infer
-{ $values { "quot" "a quotation" } { "effect" "an instance of " { $link effect } } }
+{ $values { "quot" quotation } { "effect" "an instance of " { $link effect } } }
 { $description "Attempts to infer the quotation's stack effect. For interactive testing, the " { $link infer. } " word should be called instead since it presents the output in a nicely formatted manner." }
 { $errors "Throws an " { $link inference-error } " if stack effect inference fails." } ;
 
 HELP: infer.
-{ $values { "quot" "a quotation" } }
+{ $values { "quot" quotation } }
 { $description "Attempts to infer the quotation's stack effect, and prints this data to " { $link output-stream } "." }
 { $errors "Throws an " { $link inference-error } " if stack effect inference fails." } ;
 
index 6391c1175cfdebe8c7fe4c29af7efc2f70a24931..a8612696b7200f4857400bd2b23331cc9a1e843b 100644 (file)
@@ -25,7 +25,7 @@ $nl
 ABOUT: "tools.annotations"
 
 HELP: annotate
-{ $values { "word" "a word" } { "quot" { $quotation ( old-def -- new-def ) } } }
+{ $values { "word" word } { "quot" { $quotation ( old-def -- new-def ) } } }
 { $description "Changes a word definition to the result of applying a quotation to the old definition." }
 { $notes "This word is used to implement " { $link watch } "." } ;
 
index f4d2abe2f8b2640bfd4b1867becfdc4e0f1076ca..3c47e57daee7a654e87572157093a969f1b3d83d 100644 (file)
@@ -1,5 +1,5 @@
-USING: help.markup help.syntax words definitions prettyprint
-tools.crossref.private math quotations assocs kernel sets ;
+USING: assocs help.markup help.syntax kernel math sets
+tools.crossref.private words ;
 IN: tools.crossref
 
 ARTICLE: "tools.crossref" "Definition cross referencing"
@@ -50,7 +50,7 @@ HELP: usage
 { $notes "The sequence might include the definition itself, if it is a recursive word." } ;
 
 HELP: usage.
-{ $values { "word" "a word" } }
+{ $values { "word" word } }
 { $description "Prints an list of all callers of a word. This may include the word itself, if it is recursive." }
 { $examples { $code "\\ reverse usage." } } ;
 
index de6a5ac97c0334f97af19785b79ee64f20ccfa31..675f61dbd2ce920cff90faa2853a150a496f51d0 100644 (file)
@@ -1,4 +1,5 @@
-USING: ui.gadgets ui.gestures help.markup help.syntax strings ;
+USING: help.markup help.syntax kernel strings ui.gadgets
+ui.gestures ;
 IN: ui.clipboards
 
 HELP: clipboard
@@ -6,11 +7,11 @@ HELP: clipboard
 { $class-description "A mutable container for a single string implementing the " { $link "clipboard-protocol" } "." } ;
 
 HELP: paste-clipboard
-{ $values { "gadget" gadget } { "clipboard" "an object" } }
+{ $values { "gadget" gadget } { "clipboard" object } }
 { $contract "Arranges for the contents of the clipboard to be inserted into the gadget at some point in the near future via a call to " { $link user-input } ". The gadget must be grafted." } ;
 
 HELP: copy-clipboard
-{ $values { "string" string } { "gadget" gadget } { "clipboard" "an object" } }
+{ $values { "string" string } { "gadget" gadget } { "clipboard" object } }
 { $contract "Arranges for the string to be copied to the clipboard on behalf of the gadget. The gadget must be grafted." } ;
 
 HELP: selection
index 3e5fa236ae09cc20cfe87e780f95ef4c6719c553..b1fb8086f5811ba1b493dcb3e7e290aca7cc24a9 100644 (file)
@@ -26,7 +26,7 @@ HELP: relative-loc
 } ;
 
 HELP: user-input*
-{ $values { "str" string } { "gadget" gadget } { "?" "a boolean" } }
+{ $values { "str" string } { "gadget" gadget } { "?" boolean } }
 { $contract "Handle free-form textual input while the gadget has keyboard focus." } ;
 
 HELP: children-on
@@ -49,7 +49,7 @@ HELP: each-child
 { $description "Applies the quotation to each child of the gadget." } ;
 
 HELP: gadget-selection?
-{ $values { "gadget" gadget } { "?" "a boolean" } }
+{ $values { "gadget" gadget } { "?" boolean } }
 { $contract "Outputs if the gadget has an active text selection; if so, the selected text can be obtained with a call to " { $link gadget-selection } "." } ;
 
 HELP: gadget-selection
@@ -147,7 +147,7 @@ HELP: parents
 { $description "Outputs a sequence of all parents of the gadget, with the first element being the gadget itself." } ;
 
 HELP: each-parent
-{ $values { "gadget" gadget } { "quot" { $quotation ( gadget -- ? ) } } { "?" "a boolean" } }
+{ $values { "gadget" gadget } { "quot" { $quotation ( gadget -- ? ) } } { "?" boolean } }
 { $description "Applies the quotation to every parent of the gadget, starting from the gadget itself, stopping if the quotation yields " { $link f } ". Outputs " { $link t } " if the iteration completed, and outputs " { $link f } " if it was stopped prematurely." } ;
 
 HELP: find-parent
@@ -159,7 +159,7 @@ HELP: screen-loc
 { $description "Outputs the location of the gadget relative to the top-left corner of the world containing the gadget. This word does not output a useful value if the gadget is not grafted." } ;
 
 HELP: child?
-{ $values { "parent" gadget } { "child" gadget } { "?" "a boolean" } }
+{ $values { "parent" gadget } { "child" gadget } { "?" boolean } }
 { $description "Tests if " { $snippet "child" } " is contained inside " { $snippet "parent" } "." } ;
 
 HELP: focusable-child*
index 04e6f12dfc0944dc925d03f44c2f6e1e657d1f68..97aacef3cd7dd06a42cf7e8b1c77e31e1d33c123 100644 (file)
@@ -1,5 +1,6 @@
+USING: help.markup help.syntax kernel math.rectangles
+ui.gadgets ;
 IN: ui.gadgets.glass
-USING: help.markup help.syntax ui.gadgets math.rectangles ;
 
 HELP: show-glass
 { $values { "owner" gadget } { "child" gadget } { "visible-rect" rect } }
@@ -23,7 +24,7 @@ HELP: hide-glass-hook
 { $description "Called when a gadget displayed in a glass layer is hidden. The gadget can perform cleanup tasks here." } ;
 
 HELP: pass-to-popup
-{ $values { "gesture" "a gesture" } { "owner" "the popup's owner" } { "?" "a boolean" } }
+{ $values { "gesture" "a gesture" } { "owner" "the popup's owner" } { "?" boolean } }
 { $description "Resends the gesture to the popup displayed by " { $snippet "owner" } ". The owner must have a " { $slot "popup" } " slot. Outputs " { $link f } " if the gesture was handled, " { $link t } " otherwise." } ;
 
 HELP: show-popup
@@ -54,4 +55,4 @@ $nl
     pass-to-popup
 } ;
 
-ABOUT: "ui.gadgets.glass"
\ No newline at end of file
+ABOUT: "ui.gadgets.glass"
index c59c1360feb69def078adc82ec9ac0a80d29bc5a..4940a11fdbfdbe41392d582f06ff8d1134d31261 100644 (file)
@@ -1,4 +1,4 @@
-USING: help.markup help.syntax ui.gadgets models models.range
+USING: help.markup help.syntax math math.ranges ui.gadgets
 ui.gadgets.sliders.private ;
 IN: ui.gadgets.sliders
 
@@ -18,15 +18,15 @@ HELP: thumb
 { $class-description "A thumb is the gadget contained in a " { $link slider } "'s " { $link elevator } " which indicates the current scroll position and can be dragged up and down with the mouse." } ;
 
 HELP: slide-by
-{ $values { "amount" "an integer" } { "slider" slider } }
+{ $values { "amount" integer } { "slider" slider } }
 { $description "Adds the amount (which may be positive or negative) to the slider's current position." } ;
 
 HELP: slide-by-page
-{ $values { "amount" "an integer" } { "slider" slider } }
+{ $values { "amount" integer } { "slider" slider } }
 { $description "Adds the amount multiplied by " { $link slider-page } " to the slider's current position." } ;
 
 HELP: slide-by-line
-{ $values { "amount" "an integer" } { "slider" slider } }
+{ $values { "amount" integer } { "slider" slider } }
 { $description "Adds the amount multiplied by the " { $snippet "line" } " slot to the slider's current position." } ;
 
 HELP: <slider>
index 592a3fea3af61455d378cb7456ea8dfccdbf09d9..a12ec35155dcc0873578455c06d9f30375f475f1 100644 (file)
@@ -7,7 +7,7 @@ HELP: set-gestures
 { $description "Sets the gestures a gadget class responds to. The hashtable maps gestures to quotations with stack effect " { $snippet "( gadget -- )" } "." } ;
 
 HELP: handle-gesture
-{ $values { "gesture" "a gesture" } { "gadget" "the receiver of the gesture" } { "?" "a boolean" } }
+{ $values { "gesture" "a gesture" } { "gadget" "the receiver of the gesture" } { "?" boolean } }
 { $contract "Handles a gesture sent to a gadget."
 $nl
 "Outputs " { $link f } " if the gesture was handled, and " { $link t } " if the gesture should be passed on to the gadget's parent."
@@ -16,14 +16,14 @@ $nl
 { $notes "Methods should be defined on this word if you desire to handle an arbitrary set of gestures. To define handlers for a fixed set, it is easier to use " { $link set-gestures } ". If you define a method on " { $snippet "handle-gesture" } ", you should also override " { $link handles-gesture? } "." } ;
 
 HELP: handles-gesture?
-{ $values { "gesture" "a gesture" } { "gadget" "the receiver of the gesture" } { "?" "a boolean" } }
+{ $values { "gesture" "a gesture" } { "gadget" "the receiver of the gesture" } { "?" boolean } }
 { $contract "Returns a true value if " { $snippet "gadget" } " would handle " { $snippet "gesture" } " in its " { $link handle-gesture } " method."
 $nl
 "The default implementation looks at the " { $snippet "\"gestures\"" } " word property of each superclass of the gadget's class and returns true if a handler is present for " { $snippet "gesture" } "." }
 { $notes "This word is used in Factor's MacOS X UI to validate menu items." } ;
 
 HELP: parents-handle-gesture?
-{ $values { "gesture" "a gesture" } { "gadget" "the receiver of the gesture" } { "?" "a boolean" } }
+{ $values { "gesture" "a gesture" } { "gadget" "the receiver of the gesture" } { "?" boolean } }
 { $contract "Returns a true value if " { $snippet "gadget" } " or any of its ancestors would handle " { $snippet "gesture" } " in its " { $link handle-gesture } " method." } ;
 
 { propagate-gesture handle-gesture handles-gesture? set-gestures } related-words
index b93d4f87aaa295d2e9df07df0bfbb7cc224a05a5..26bf248174f60f4dc9d8e464b62328cbe13ebf7e 100644 (file)
@@ -65,7 +65,7 @@ HELP: define-operation-map
 { $description "Defines a command map named " { $snippet "group" } " on " { $snippet "class" } " consisting of operations applicable to " { $snippet "object" } ". The translator quotation is applied to the target gadget, and the result of the translator is passed to the operation." } ;
 
 HELP: $operations
-{ $values { "element" "a sequence" } }
+{ $values { "element" sequence } }
 { $description "Converts the element to a quotation and calls it; the resulting quotation must have stack effect " { $snippet "( -- obj )" } ". Prints a list of operations applicable to the object, together with keyboard shortcuts." } ;
 
 HELP: $operation
index d6cbf2301dd705fa33a8dab3ad2def8ded0b38eb..f6ded4cffe26ac75aab3daf00b7f1ac4d3b8c802 100644 (file)
@@ -32,11 +32,11 @@ HELP: world-attributes
 } ;
 
 HELP: set-fullscreen
-{ $values { "gadget" gadget } { "?" "a boolean" } }
+{ $values { "gadget" gadget } { "?" boolean } }
 { $description "Sets and unsets fullscreen mode for the gadget's world." } ;
 
 HELP: fullscreen?
-{ $values { "gadget" gadget } { "?" "a boolean" } }
+{ $values { "gadget" gadget } { "?" boolean } }
 { $description "Queries the gadget's world to see if it is running in fullscreen mode." } ;
 
 { fullscreen? set-fullscreen } related-words
index 7e4ac10e19b01cf10bf66c1dea97940f593d747d..845eadc84a602119664830b4cbb0b18bfe71968d 100644 (file)
@@ -1,4 +1,4 @@
-USING: help.syntax help.markup strings ;
+USING: help.syntax help.markup kernel strings ;
 IN: unicode.case
 
 ABOUT: "unicode.case"
@@ -39,17 +39,17 @@ HELP: >case-fold
 { $description "Converts a string to case-folded form." } ;
 
 HELP: upper?
-{ $values { "string" string } { "?" "a boolean" } }
+{ $values { "string" string } { "?" boolean } }
 { $description "Tests if a string is in upper case." } ;
 
 HELP: lower?
-{ $values { "string" string } { "?" "a boolean" } }
+{ $values { "string" string } { "?" boolean } }
 { $description "Tests if a string is in lower case." } ;
 
 HELP: title?
-{ $values { "string" string } { "?" "a boolean" } }
+{ $values { "string" string } { "?" boolean } }
 { $description "Tests if a string is in title case." } ;
 
 HELP: case-fold?
-{ $values { "string" string } { "?" "a boolean" } }
+{ $values { "string" string } { "?" boolean } }
 { $description "Tests if a string is in case-folded form." } ;
index 563987ae75a8406650c5dc55271a2bf123f7c283..edfa81d0a34dae56527b6107732fa84101f69565 100644 (file)
@@ -1,6 +1,6 @@
 ! Copyright (C) 2009 Daniel Ehrenberg
 ! See http://factorcode.org/license.txt for BSD license.
-USING: help.syntax help.markup strings ;
+USING: help.syntax help.markup kernel math strings ;
 IN: unicode.data
 
 ABOUT: "unicode.data"
@@ -35,11 +35,11 @@ HELP: compatibility-entry
 { $description "This returns the compatibility decomposition (NFKD) for a code point" } ;
 
 HELP: combining-class
-{ $values { "char" "a code point" } { "n" "an integer" } }
+{ $values { "char" "a code point" } { "n" integer } }
 { $description "Finds the combining class of a code point." } ;
 
 HELP: non-starter?
-{ $values { "char" "a code point" } { "?" "a boolean" } }
+{ $values { "char" "a code point" } { "?" boolean } }
 { $description "Returns true if the code point has a combining class." } ;
 
 HELP: char>name
@@ -51,7 +51,7 @@ HELP: name>char
 { $description "Looks up the code point corresponding to a given name." } ;
 
 HELP: property?
-{ $values { "char" "a code point" } { "property" string } { "?" "a boolean" } }
+{ $values { "char" "a code point" } { "property" string } { "?" boolean } }
 { $description "Tests whether the code point is listed under the given property in PropList.txt in the Unicode Character Database." } ;
 
 HELP: category
index 1f2b6e8e47f23d70d6b42ee764932400bc3da4c9..e4947d602140495fe53450d6bdb15ee1c4e7a209 100644 (file)
@@ -1,4 +1,4 @@
-USING: strings help.markup help.syntax assocs urls ;
+USING: assocs help.markup help.syntax kernel strings ;
 IN: urls.encoding
 
 HELP: url-decode
@@ -14,7 +14,7 @@ HELP: url-encode-full
 { $description "URL-encodes a string, including all reserved characters, such as \"/\"." } ;
 
 HELP: url-quotable?
-{ $values { "ch" "a character" } { "?" "a boolean" } }
+{ $values { "ch" "a character" } { "?" boolean } }
 { $description "Tests if a character be used without URL-encoding in a URL." } ;
 
 HELP: assoc>query
index 46deab82b935148949a0c8e9ffb5ca015cde7302..e5d00299063008aec594cf7a7050ea0091addf0f 100644 (file)
@@ -133,11 +133,11 @@ HELP: relative-url
 HELP: relative-url?
 { $values
      { "url" url }
-     { "?" "a boolean" } }
+     { "?" boolean } }
 { $description "Tests whether a URL is relative." } ;
 
 HELP: secure-protocol?
-{ $values { "protocol" string } { "?" "a boolean" } }
+{ $values { "protocol" string } { "?" boolean } }
 { $description "Tests if protocol connections must be made with secure sockets (SSL/TLS)." }
 { $examples
     { $example
index 41f80ee65cd898ca9eb95d1525d9f79379df697e..1b6deef126fa9ce07ebde01082e4ed1d56c0063b 100644 (file)
@@ -1,9 +1,9 @@
-USING: help.markup help.syntax io.streams.string quotations 
-strings math regexp ;
+USING: help.markup help.syntax kernel math quotations regexp
+strings ;
 IN: validators
 
 HELP: v-checkbox
-{ $values { "str" string } {  "?" "a boolean" } }
+{ $values { "str" string } {  "?" boolean } }
 { $description "Converts the string value of a checkbox component (either \"on\" or \"off\") to a boolean value." } ;
 
 HELP: v-captcha
index ee02a491e134052ede801cd33c29eb06318caee1..fd301c3c8def08fc6a872053778ab0a4327b6866 100644 (file)
@@ -1,8 +1,8 @@
-USING: help.markup help.syntax strings ;
+USING: help.markup help.syntax kernel strings ;
 IN: vocabs.refresh
 
 HELP: source-modified?
-{ $values { "path" "a pathname string" } { "?" "a boolean" } }
+{ $values { "path" "a pathname string" } { "?" boolean } }
 { $description "Tests if the source file has been modified since it was last loaded. This compares the file's CRC32 checksum of the file's contents against the previously-recorded value." } ;
 
 HELP: refresh
index b7e0b9c96d5b978cad84c2916131b9492e49164e..f403ac6ffb9ce6b7b5a17c8658b0ce0237831a06 100644 (file)
@@ -1,4 +1,4 @@
-USING: help.syntax help.markup ;
+USING: help.syntax help.markup math sequences strings ;
 IN: xml-rpc
 
 HELP: send-rpc
@@ -12,7 +12,7 @@ HELP: receive-rpc
 { $see-also send-rpc } ;
 
 HELP: <base64>
-{ $values { "string" "a string" } { "base64" "a base64 tuple" } }
+{ $values { "string" string } { "base64" "a base64 tuple" } }
 { $description "creates a base64 tuple using the data in the string. This marks the data for encoding in the base64 format" }
 { $see-also base64 } ;
 
@@ -21,7 +21,7 @@ HELP: base64
 { $see-also <base64> } ;
 
 HELP: <rpc-method>
-{ $values { "name" "a string" } { "params" "a sequence" } { "rpc-method" rpc-method } }
+{ $values { "name" string } { "params" sequence } { "rpc-method" rpc-method } }
 { $description "creates a tuple representing a method call which can be translated using send-rpc into an XML-RPC document" }
 { $see-also rpc-method <rpc-response> <rpc-fault> } ;
 
@@ -30,7 +30,7 @@ HELP: rpc-method
 { $see-also <rpc-method> rpc-response rpc-fault } ;
 
 HELP: <rpc-response>
-{ $values { "params" "a sequence" } { "rpc-response" rpc-response } }
+{ $values { "params" sequence } { "rpc-response" rpc-response } }
 { $description "creates a tuple representing a data response in XML-RPC" }
 { $see-also rpc-response <rpc-method> <rpc-fault> } ;
 
@@ -39,7 +39,7 @@ HELP: rpc-response
 { $see-also <rpc-response> rpc-method rpc-fault } ;
 
 HELP: <rpc-fault>
-{ $values { "code" "an integer" } { "string" "a string" } { "rpc-fault" rpc-fault } }
+{ $values { "code" integer } { "string" string } { "rpc-fault" rpc-fault } }
 { $description "creates a tuple representing an exception in RPC, to be returned to the caller. The code is a number representing what type of error it is, and the string is a description" }
 { $see-also rpc-fault <rpc-method> <rpc-response> } ;
 
index 17a63348e37524cb67bad7935fa9adc8bda9e4df..2e73d606aadfdf349a9226ebb003e7ba40e06615 100644 (file)
@@ -1,4 +1,4 @@
-USING: help.markup help.syntax sequences strings ;
+USING: help.markup help.syntax kernel sequences strings ;
 IN: xml.data
 
 ABOUT: "xml.data"
@@ -78,7 +78,7 @@ HELP: name
 { $see-also <name> tag } ;
 
 HELP: <name>
-{ $values { "space" "a string" } { "main" "a string" } { "url" "a string" }
+{ $values { "space" string } { "main" string } { "url" string }
     { "name" "an XML tag name" } }
 { $description "Creates a name tuple with the namespace prefix space, the the given main part of the name, and the namespace URL given by url." }
 { $see-also name <tag> } ;
@@ -110,7 +110,7 @@ HELP: prolog
 
 HELP: <prolog>
 { $values { "version" "a string, 1.0 or 1.1" }
-{ "encoding" "a string" } { "standalone" "a boolean" } { "prolog" "an XML prolog" } }
+{ "encoding" string } { "standalone" boolean } { "prolog" "an XML prolog" } }
 { $description "Creates an XML prolog tuple." }
 { $see-also prolog <xml> } ;
 
@@ -128,7 +128,7 @@ HELP: instruction
 { $see-also <instruction> } ;
 
 HELP: <instruction>
-{ $values { "text" "a string" } { "instruction" "an XML instruction" } }
+{ $values { "text" string } { "instruction" "an XML instruction" } }
 { $description "Creates an XML parsing instruction, like " { $snippet "<?xsl stylesheet='foo.xml'?>" } "." }
 { $see-also instruction } ;
 
index 39c3951043f11357de4b0f4c0ce5bf5a61a33e72..fb7109eebba96d7f79a87ce3ffd81e175833c064 100644 (file)
@@ -49,7 +49,7 @@ HELP: deep-tags-named
 { $see-also tag-named deep-tag-named tags-named } ;
 
 HELP: children>string
-{ $values { "tag" "an XML tag or document" } { "string" "a string" } }
+{ $values { "tag" "an XML tag or document" } { "string" string } }
 { $description "Concatenates the children of the tag, throwing an exception when there is a non-string child." } ;
 
 HELP: children-tags
@@ -86,5 +86,5 @@ HELP: tags-named
 { $see-also deep-tag-named deep-tags-named tag-named } ;
 
 HELP: get-id
-{ $values { "tag" "an XML tag or document" } { "id" "a string" } { "elem" "an XML element or f" } }
+{ $values { "tag" "an XML tag or document" } { "id" string } { "elem" "an XML element or f" } }
 { $description "Finds the XML tag with the specified id, ignoring the namespace." } ;
index 77f4808bfa37d91c4c4464799e02361c93684ef3..0702e5be4ea8a3c4e174ff3ca3edb373737506f3 100644 (file)
@@ -24,12 +24,12 @@ ARTICLE: "xml.writer" "Writing XML"
 "All of these words operate on arbitrary pieces of XML: they can take, as in put, XML documents, comments, tags, strings (text nodes), XML chunks, etc." ;
 
 HELP: xml>string
-{ $values { "xml" "an XML document" } { "string" "a string" } }
+{ $values { "xml" "an XML document" } { "string" string } }
 { $description "This converts an XML document " { $link xml } " into a string. It can also be used to convert any piece of XML to a string, eg an " { $link xml-chunk } " or " { $link comment } "." }
 { $notes "This does not preserve what type of quotes were used or what data was omitted from version declaration, as that information isn't present in the XML data representation. The whitespace in the text nodes of the original document is preserved." } ;
 
 HELP: pprint-xml>string
-{ $values { "xml" "an XML document" } { "string" "a string" } }
+{ $values { "xml" "an XML document" } { "string" string } }
 { $description "Converts an XML document into a string in a prettyprinted form." }
 { $notes "This does not preserve what type of quotes were used or what data was omitted from version declaration, as that information isn't present in the XML data representation. The whitespace in the text nodes of the original document is preserved." } ;
 
index 25a8618ebb64b3359b9fb2d0b52708790753e2de..4230d14631363cf8d5962d730b6b4670f70ae7d9 100644 (file)
@@ -1,7 +1,6 @@
 USING: alien.accessors alien.c-types alien.libraries
-alien.syntax arrays byte-arrays compiler cpu.x86
-debugger definitions eval help.markup help.syntax io io.backend
-kernel libc math parser quotations sequences system ;
+alien.syntax byte-arrays cpu.x86 eval help.markup help.syntax io
+io.backend kernel math quotations sequences system ;
 IN: alien
 
 HELP: cdecl
@@ -41,11 +40,11 @@ HELP: dll
 { $class-description "The class of native library handles. See " { $link "syntax-aliens" } " for syntax and " { $link "dll.private" } " for general information." } ;
 
 HELP: dll-valid?
-{ $values { "dll" dll } { "?" "a boolean" } }
+{ $values { "dll" dll } { "?" boolean } }
 { $description "Returns true if the library exists and is loaded." } ;
 
 HELP: expired?
-{ $values { "c-ptr" c-ptr } { "?" "a boolean" } }
+{ $values { "c-ptr" c-ptr } { "?" boolean } }
 { $description "Tests if the alien is a relic from an earlier session. A byte array is never considered to have expired, whereas passing " { $link f } " always yields true." } ;
 
 HELP: <bad-alien>
@@ -53,7 +52,7 @@ HELP: <bad-alien>
 { $description "Constructs an invalid alien pointer that has expired." } ;
 
 HELP: <displaced-alien>
-{ $values { "displacement" "an integer" } { "c-ptr" c-ptr } { "alien" "a new alien" } }
+{ $values { "displacement" integer } { "c-ptr" c-ptr } { "alien" "a new alien" } }
 { $description "Creates a new alien address object, wrapping a raw memory address. The alien points to a location in memory which is offset by " { $snippet "displacement" } " from the address of " { $snippet "c-ptr" } "." }
 { $notes "Passing a value of " { $link f } " for " { $snippet "c-ptr" } " creates an alien with an absolute address; this is how " { $link <alien> } " is implemented."
 $nl
index 2310ff9ccdb162c03b7f17a5e05516cb1cf6edc9..cd23dfc87d99f738ee521ce5b9e0a6a6a7b4f019 100644 (file)
@@ -1,5 +1,5 @@
-USING: help.markup help.syntax kernel classes classes.private words\r
-checksums checksums.crc32 sequences math ;\r
+USING: classes classes.private help.markup help.syntax kernel\r
+math sequences ;\r
 IN: classes.algebra\r
 \r
 ARTICLE: "class-operations" "Class operations"\r
@@ -45,7 +45,7 @@ HELP: flatten-class
 { $description "Outputs a set of builtin and tuple classes whose union is the smallest cover of " { $snippet "class" } "." } ;\r
 \r
 HELP: class<=\r
-{ $values { "first" "a class" } { "second" "a class" } { "?" "a boolean" } }\r
+{ $values { "first" "a class" } { "second" "a class" } { "?" boolean } }\r
 { $description "Tests if all instances of " { $snippet "class1" } " are also instances of " { $snippet "class2" } "." }\r
 { $notes "Classes are partially ordered. This means that if " { $snippet "class1 <= class2" } " and " { $snippet "class2 <= class1" } ", then " { $snippet "class1 <= class2" } ". Also, if " { $snippet "class1 <= class2" } " and " { $snippet "class2 <= class3" } ", then " { $snippet "class1 <= class3" } "." } ;\r
 \r
@@ -62,7 +62,7 @@ HELP: class-and
 { $description "Outputs the largest anonymous class contained in both " { $snippet "class1" } " and " { $snippet "class2" } "." } ;\r
 \r
 HELP: classes-intersect?\r
-{ $values { "first" class } { "second" class } { "?" "a boolean" } }\r
+{ $values { "first" class } { "second" class } { "?" boolean } }\r
 { $description "Tests if two classes have a non-empty intersection. If the intersection is empty, no object can be an instance of both classes at once." } ;\r
 \r
 HELP: smallest-class\r
index ec118be4aa913a668ebc90d9b4e8170e6bc07db8..29ac0dee4304d9ad292931a20a84ae2679f20d5d 100644 (file)
@@ -1,7 +1,5 @@
-USING: help.markup help.syntax kernel kernel.private
-namespaces sequences words arrays effects math
-classes.private classes.union classes.mixin
-classes.predicate quotations ;
+USING: classes.private help.markup help.syntax kernel quotations
+sequences words ;
 IN: classes
 
 ARTICLE: "class-predicates" "Class predicate words"
@@ -87,7 +85,7 @@ HELP: update-map
 { $var-description "Assoc mapping each class to a set of classes defined in terms of this class. The " { $link define-class } " word uses this information to update generic words when classes are redefined." } ;
 
 HELP: predicate-word
-{ $values { "word" "a word" } { "predicate" "a predicate word" } }
+{ $values { "word" word } { "predicate" "a predicate word" } }
 { $description "Suffixes the word's name with \"?\" and creates a word with that name in the same vocabulary as the word itself." } ;
 
 HELP: define-predicate
@@ -153,7 +151,7 @@ HELP: implementors
 HELP: instance?
 { $values
      { "object" object } { "class" class }
-     { "?" "a boolean" } }
+     { "?" boolean } }
 { $description "Tests whether the input object is a member of the class." } ;
 
 HELP: reset-class
index 1676e05c76a9d8fcc3a5ae588fd8c15453874d4a..1d879e4fa2e002a6be74e1b06519321650ee4fb1 100644 (file)
@@ -1,7 +1,6 @@
-USING: generic help.markup help.syntax kernel
-classes.tuple.private classes slots quotations words arrays
-generic.standard sequences definitions compiler.units
-growable vectors sbufs assocs math strings ;
+USING: arrays assocs classes classes.tuple.private
+compiler.units growable help.markup help.syntax kernel math
+sbufs sequences slots strings vectors words ;
 IN: classes.tuple
 
 ARTICLE: "slot-read-only-declaration" "Read-only slots"
@@ -353,7 +352,7 @@ HELP: tuple-class
 { $examples { $example "USING: classes.tuple prettyprint ;" "IN: scratchpad" "TUPLE: name title first last ;" "name tuple-class? ." "t" } } ;
 
 HELP: tuple=
-{ $values { "tuple1" tuple } { "tuple2" tuple } { "?" "a boolean" } }
+{ $values { "tuple1" tuple } { "tuple2" tuple } { "?" boolean } }
 { $description "Checks if two tuples have equal slot values. This is the default behavior of " { $link = } " on tuples, unless the tuple class subclasses " { $link identity-tuple } " or implements a method on " { $link equal? } ". In cases where equality has been redefined, this word can be used to get the default semantics if needed." } ;
 
 HELP: tuple
index 3444875d89fa60dae7dbc65859c61bd687c7718a..e80cc42ee65f9aa31d4ab523204239c21b8974ca 100644 (file)
@@ -312,7 +312,7 @@ HELP: to-fixed-point
 } ;
 
 HELP: alist>quot
-{ $values { "default" "a quotation" } { "assoc" "a sequence of quotation pairs" } { "quot" "a new quotation" } }
+{ $values { "default" quotation } { "assoc" "a sequence of quotation pairs" } { "quot" "a new quotation" } }
 { $description "Constructs a quotation which calls the first quotation in each pair of " { $snippet "assoc" } " until one of them outputs a true value, and then calls the second quotation in the corresponding pair. Quotations are called in reverse order, and if no quotation outputs a true value then " { $snippet "default" } " is called." }
 { $notes "This word is used to implement compile-time behavior for " { $link cond } ", and it is also used by the generic word system. Note that unlike " { $link cond } ", the constructed quotation performs the tests starting from the end and not the beginning." } ;
 
index 93e8a468ee59c5320f1b4d1d0ac142f8d2406462..c370018c461c1b2ac7e5f708be49d928d69bc565 100644 (file)
@@ -1,5 +1,5 @@
-USING: help.markup help.syntax words math source-files
-parser quotations definitions stack-checker.errors ;
+USING: definitions help.markup help.syntax kernel parser
+quotations source-files stack-checker.errors words ;
 IN: compiler.units
 
 ARTICLE: "compilation-units-internals" "Compilation units internals"
@@ -79,7 +79,7 @@ HELP: no-compilation-unit
 { $error-description "Thrown when an attempt is made to define a word outside of a " { $link with-compilation-unit } " combinator." } ;
 
 HELP: modify-code-heap
-{ $values { "alist" "an association list with words as keys" } { "update-existing?" "a boolean" } { "reset-pics?" "a boolean" } }
+{ $values { "alist" "an association list with words as keys" } { "update-existing?" boolean } { "reset-pics?" boolean } }
 { $description "Lowest-level primitive for defining words. Associates words with code blocks in the code heap."
 $nl
 "The alist maps words to one of the following:"
index f69a03bfc10ee40420f548835409d90ec565161c..12c259a485d6edb11c41771b2ec8155e20cb6019 100644 (file)
@@ -1,6 +1,5 @@
-USING: help.markup help.syntax kernel kernel.private
-continuations.private vectors arrays namespaces
-assocs words quotations lexer sequences math ;
+USING: continuations.private help.markup help.syntax kernel
+kernel.private lexer namespaces quotations sequences vectors ;
 IN: continuations
 
 ARTICLE: "errors-restartable" "Restartable errors"
@@ -216,7 +215,7 @@ HELP: throw-continue
 { $description "Throws a resumable error. If the user elects to continue execution, this word returns normally." } ;
 
 HELP: compute-restarts
-{ $values { "error" object } { "seq" "a sequence" } }
+{ $values { "error" object } { "seq" sequence } }
 { $description "Outputs a sequence of triples, where each triple consists of a human-readable string, an object, and a continuation. Resuming a continuation with the corresponding object restarts execution immediately after the corresponding call to " { $link condition } "."
 $nl
 "This word recursively travels up the delegation chain to collate restarts from nested and wrapped conditions." } ;
index 699eb39a8a839ce32924cbc9e958dd18f15a0c96..a6ad46ede58a66fb1678fe35b246708efcba8513 100644 (file)
@@ -1,5 +1,4 @@
-USING: help.markup help.syntax libc kernel continuations io
-sequences classes ;
+USING: classes help.markup help.syntax io quotations sequences ;
 IN: destructors
 
 HELP: debug-leaks?
@@ -41,7 +40,7 @@ HELP: with-disposal
 { $description "Calls the quotation, disposing the object with " { $link dispose } " after the quotation returns or if it throws an error." } ;
 
 HELP: with-destructors
-{ $values { "quot" "a quotation" } }
+{ $values { "quot" quotation } }
 { $description "Calls a quotation within a new dynamic scope. This quotation may register destructors using " { $link &dispose } " or " { $link |dispose } ". The former registers a destructor that will always run whether or not the quotation threw an error, and the latter registers a destructor that only runs if the quotation throws an error. Destructors are run in reverse order from the order in which they were registered." }
 { $notes
     "Destructors generalize " { $link with-disposal } ". The following two lines are equivalent, except that the second line establishes a new dynamic scope:"
index da151991a5d4931b6fabdc4d7c3fb5a190ce3cd2..f514c4716405355fabc57374b18c3efe37883f22 100644 (file)
@@ -1,4 +1,5 @@
-USING: arrays classes help.markup help.syntax math strings words kernel combinators sequences ;
+USING: arrays classes help.markup help.syntax kernel math
+sequences strings words ;
 IN: effects
 
 ARTICLE: "effects" "Stack effect declarations"
@@ -124,11 +125,11 @@ HELP: effect-height
 { $description "Outputs the number of objects added to the data stack by the stack effect. This will be negative if the stack effect only removes objects from the stack." } ;
 
 HELP: effect<=
-{ $values { "effect1" effect } { "effect2" effect } { "?" "a boolean" } }
+{ $values { "effect1" effect } { "effect2" effect } { "?" boolean } }
 { $description "Tests if " { $snippet "effect1" } " is substitutable for " { $snippet "effect2" } ". What this means is that both stack effects change the stack height by the same amount, the first takes a smaller or equal number of inputs as the second, and either both or neither one terminate execution by throwing an error." } ;
 
 HELP: effect=
-{ $values { "effect1" effect } { "effect2" effect } { "?" "a boolean" } }
+{ $values { "effect1" effect } { "effect2" effect } { "?" boolean } }
 { $description "Tests if " { $snippet "effect1" } " and " { $snippet "effect2" } " represent the same stack transformation, without looking parameter names." }
 { $examples
   { $example "USING: effects prettyprint ;" "( a -- b ) ( x -- y ) effect= ." "t" }
index 33da0037b375db9dc9915ec05a62d58f2cc8f2de..13e4554b5a4a718af59dbbe39cc899767cd3e03e 100644 (file)
@@ -1,5 +1,4 @@
-USING: generic generic.single help.markup help.syntax sequences math
-math.parser effects ;
+USING: effects generic.single help.markup help.syntax words ;
 IN: generic.standard
 
 HELP: standard-combination
@@ -18,5 +17,5 @@ HELP: standard-combination
 } ;
 
 HELP: define-simple-generic
-{ $values { "word" "a word" } { "effect" effect } }
-{ $description "Defines a generic word with the " { $link standard-combination } " method combination and a dispatch position of 0." } ;
\ No newline at end of file
+{ $values { "word" word } { "effect" effect } }
+{ $description "Defines a generic word with the " { $link standard-combination } " method combination and a dispatch position of 0." } ;
index e86996549313a703ae49db5df415bab4cf04c07a..5ccf6f3829e4adc2fdf24b77b859171aaf87d135 100644 (file)
@@ -1,6 +1,5 @@
-USING: hashtables.private help.markup help.syntax
-kernel prettyprint generic sequences sequences.private
-namespaces assocs ;
+USING: assocs hashtables.private help.markup help.syntax kernel
+sequences ;
 IN: hashtables
 
 ARTICLE: "hashtables.private" "Hashtable implementation details"
@@ -80,7 +79,7 @@ HELP: new-key@
 { $description "Searches the hashtable for the key using a quadratic probing strategy. If the key is not present in the hashtable, outputs the index where it should be stored." } ;
 
 HELP: set-nth-pair
-{ $values { "value" "the second element of the pair" } { "key" "the first element of the pair" } { "seq" "a sequence" } { "n" "an index in the sequence" } }
+{ $values { "value" "the second element of the pair" } { "key" "the first element of the pair" } { "seq" sequence } { "n" "an index in the sequence" } }
 { $description "Stores a pair of values into the elements with index " { $snippet "n" } " and " { $snippet "n+1" } ", respectively." }
 { $warning "This word is in the " { $vocab-link "hashtables.private" } " vocabulary because it does not perform bounds checks." }
 { $side-effects "seq" } ;
index c6e7e801d2889718cda13d4bdf9e94256c903145..3731b93f6011c198e0b9c8ca1f4c9ac11d33712a 100644 (file)
@@ -1,5 +1,4 @@
-USING: help.markup help.syntax io strings arrays io.backend
-io.files.private quotations sequences ;
+USING: help.markup help.syntax io kernel quotations sequences ;
 IN: io.files
 
 ARTICLE: "io.files.examples" "Examples of reading and writing files"
@@ -57,17 +56,17 @@ HELP: <file-appender>
 { $errors "Throws an error if the file cannot be opened for writing." } ;
 
 HELP: with-file-reader
-{ $values { "path" "a pathname string" } { "encoding" "an encoding descriptor" } { "quot" "a quotation" } }
+{ $values { "path" "a pathname string" } { "encoding" "an encoding descriptor" } { "quot" quotation } }
 { $description "Opens a file for reading and calls the quotation using " { $link with-input-stream } "." }
 { $errors "Throws an error if the file is unreadable." } ;
 
 HELP: with-file-writer
-{ $values { "path" "a pathname string" } { "encoding" "an encoding descriptor" } { "quot" "a quotation" } }
+{ $values { "path" "a pathname string" } { "encoding" "an encoding descriptor" } { "quot" quotation } }
 { $description "Opens a file for writing using the given encoding and calls the quotation using " { $link with-output-stream } "." }
 { $errors "Throws an error if the file cannot be opened for writing." } ;
 
 HELP: with-file-appender
-{ $values { "path" "a pathname string" } { "encoding" "an encoding descriptor" } { "quot" "a quotation" } }
+{ $values { "path" "a pathname string" } { "encoding" "an encoding descriptor" } { "quot" quotation } }
 { $description "Opens a file for appending using the given encoding and calls the quotation using " { $link with-output-stream } "." }
 { $errors "Throws an error if the file cannot be opened for writing." } ;
 
@@ -101,5 +100,5 @@ HELP: file-contents
 { set-file-lines file-lines set-file-contents file-contents } related-words
 
 HELP: exists?
-{ $values { "path" "a pathname string" } { "?" "a boolean" } }
+{ $values { "path" "a pathname string" } { "?" boolean } }
 { $description "Tests if the file named by " { $snippet "path" } " exists." } ;
index 0eee8e87b9546a4d1aa4fbcab64d9bd11bfbbd17..207a1a0518ad0e623a5e06dfb924de8d59909df1 100644 (file)
@@ -1,9 +1,9 @@
-USING: help.markup help.syntax io.backend io.files
-io.directories strings system sequences io.pathnames.private ;
+USING: help.markup help.syntax io.backend io.directories
+io.files io.pathnames.private kernel sequences strings system ;
 IN: io.pathnames
 
 HELP: path-separator?
-{ $values { "ch" "a code point" } { "?" "a boolean" } }
+{ $values { "ch" "a code point" } { "?" boolean } }
 { $description "Tests if the code point is a platform-specific path separator." }
 { $examples
     "On Unix:"
@@ -68,15 +68,15 @@ HELP: prepend-path
 { append-path prepend-path } related-words
 
 HELP: absolute-path?
-{ $values { "path" "a pathname string" } { "?" "a boolean" } }
+{ $values { "path" "a pathname string" } { "?" boolean } }
 { $description "Tests if a pathname is absolute. Examples of absolute pathnames are " { $snippet "/foo/bar" } " on Unix and " { $snippet "c:\\foo\\bar" } " on Windows." } ;
 
 HELP: windows-absolute-path?
-{ $values { "path" "a pathname string" } { "?" "a boolean" } }
+{ $values { "path" "a pathname string" } { "?" boolean } }
 { $description "Tests if a pathname is absolute on Windows. Examples of absolute pathnames on Windows are " { $snippet "c:\\foo\\bar" } " and " { $snippet "\\\\?\\c:\\foo\\bar" } " for absolute Unicode pathnames." } ;
 
 HELP: root-directory?
-{ $values { "path" "a pathname string" } { "?" "a boolean" } }
+{ $values { "path" "a pathname string" } { "?" boolean } }
 { $description "Tests if a pathname is a root directory. Examples of root directory pathnames are " { $snippet "/" } " on Unix and " { $snippet "c:\\" } " on Windows." } ;
 
 { absolute-path? windows-absolute-path? root-directory? } related-words
index 9d42aa43d629522087371ca86289485c1da8db17..37b60d45b2e02e4cf884483f878981a5f72daa0d 100644 (file)
@@ -1,11 +1,9 @@
-USING: generic help.markup help.syntax math memory
-namespaces sequences kernel.private layouts classes
-vectors combinators quotations strings words
-assocs arrays math.order ;
+USING: arrays classes combinators help.markup help.syntax
+kernel.private layouts math quotations words ;
 IN: kernel
 
 HELP: eq?
-{ $values { "obj1" object } { "obj2" object } { "?" "a boolean" } }
+{ $values { "obj1" object } { "obj2" object } { "?" boolean } }
 { $description "Tests if two references point at the same object." } ;
 
 HELP: drop  $shuffle ;
@@ -81,7 +79,7 @@ HELP: identity-hashcode
 { hashcode hashcode* identity-hashcode } related-words
 
 HELP: =
-{ $values { "obj1" object } { "obj2" object } { "?" "a boolean" } }
+{ $values { "obj1" object } { "obj2" object } { "?" boolean } }
 { $description
     "Tests if two objects are equal. If " { $snippet "obj1" } " and " { $snippet "obj2" } " point to the same object, outputs " { $link t } ". Otherwise, calls the " { $link equal? } " generic word."
 }
@@ -94,7 +92,7 @@ HELP: =
 } ;
 
 HELP: equal?
-{ $values { "obj1" object } { "obj2" object } { "?" "a boolean" } }
+{ $values { "obj1" object } { "obj2" object } { "?" boolean } }
 { $contract
     "Tests if two objects are equal."
     $nl
@@ -136,11 +134,11 @@ HELP: boolean
 { $class-description "A union of the " { $link POSTPONE: t } " and " { $link POSTPONE: f } " classes." } ;
 
 HELP: >boolean
-{ $values { "obj" "a generalized boolean" } { "?" "a boolean" } }
+{ $values { "obj" "a generalized boolean" } { "?" boolean } }
 { $description "Convert a generalized boolean into a boolean. That is, " { $link f } " retains its value, whereas anything else becomes " { $link t } "." } ;
 
 HELP: not
-{ $values { "obj" "a generalized boolean" } { "?" "a boolean" } }
+{ $values { "obj" "a generalized boolean" } { "?" boolean } }
 { $description "For " { $link f } " outputs " { $link t } " and for anything else outputs " { $link f } "." }
 { $notes "This word implements boolean not, so applying it to integers will not yield useful results (all integers have a true value). Bitwise not is the " { $link bitnot } " word." } ;
 
@@ -171,7 +169,7 @@ HELP: xor
 { $notes "This word implements boolean exclusive or, so applying it to integers will not yield useful results (all integers have a true value). Bitwise exclusive or is the " { $link bitxor } " word." } ;
 
 HELP: both?
-{ $values { "x" object } { "y" object } { "quot" { $quotation ( ... obj -- ... ? ) } } { "?" "a boolean" } }
+{ $values { "x" object } { "y" object } { "quot" { $quotation ( ... obj -- ... ? ) } } { "?" boolean } }
 { $description "Tests if the quotation yields a true value when applied to both " { $snippet "x" } " and " { $snippet "y" } "." }
 { $examples
     { $example "USING: kernel math prettyprint ;" "3 5 [ odd? ] both? ." "t" }
@@ -179,7 +177,7 @@ HELP: both?
 } ;
 
 HELP: either?
-{ $values { "x" object } { "y" object } { "quot" { $quotation ( ... obj -- ... ? ) } } { "?" "a boolean" } }
+{ $values { "x" object } { "y" object } { "quot" { $quotation ( ... obj -- ... ? ) } } { "?" boolean } }
 { $description "Tests if the quotation yields a true value when applied to either " { $snippet "x" } " or " { $snippet "y" } "." }
 { $examples
     { $example "USING: kernel math prettyprint ;" "3 6 [ odd? ] either? ." "t" }
@@ -187,7 +185,7 @@ HELP: either?
 } ;
 
 HELP: same?
-{ $values { "x" object } { "y" object } { "quot" { $quotation ( ... obj -- ... obj' ) } } { "?" "a boolean" } }
+{ $values { "x" object } { "y" object } { "quot" { $quotation ( ... obj -- ... obj' ) } } { "?" boolean } }
 { $description "Applies the quotation to both " { $snippet "x" } " and " { $snippet "y" } ", and then checks if the results are equal." }
 { $examples
     { $example "USING: kernel math prettyprint ;" "4 5 [ 2/ ] same? ." "t" }
index 61f0b717e4598fe9435b668fcd92e9f74ea837ad..805ba90c2d8755927215693983e4ba5454341c10 100644 (file)
@@ -28,7 +28,7 @@ HELP: <lexer-error>
 { $description "Creates a new " { $link lexer-error } ", filling in the location information from the current " { $link lexer } "." } ;
 
 HELP: skip
-{ $values { "i" "a starting index" } { "seq" sequence } { "?" "a boolean" } { "n" integer } }
+{ $values { "i" "a starting index" } { "seq" sequence } { "?" boolean } { "n" integer } }
 { $description "Skips to the first space character (if " { $snippet "boolean" } " is " { $link f } ") or the first non-space character (otherwise). Tabulations used as separators instead of spaces will be flagged as an error." } ;
 
 HELP: change-lexer-column
@@ -50,7 +50,7 @@ HELP: skip-word
 { $notes "Custom lexers can implement this generic word." } ;
 
 HELP: still-parsing-line?
-{ $values { "lexer" lexer } { "?" "a boolean" } }
+{ $values { "lexer" lexer } { "?" boolean } }
 { $description "Outputs " { $link f } " if the end of the current line has been reached, " { $link t } " otherwise." } ;
 
 HELP: parse-token
@@ -68,7 +68,7 @@ HELP: scan-token
 $parsing-note ;
 
 HELP: still-parsing?
-{ $values { "lexer" lexer } { "?" "a boolean" } }
+{ $values { "lexer" lexer } { "?" boolean } }
 { $description "Outputs " { $link f } " if end of input has been reached, " { $link t } " otherwise." } ;
 
 HELP: each-token
index 2eedd0f194f0b1806caf5b809e7366d8492d57c1..e119a017cae020c1b135453acaf8fa6070cd1430 100644 (file)
@@ -1,4 +1,4 @@
-USING: help.markup help.syntax math math.private ;
+USING: help.markup help.syntax kernel math math.private ;
 IN: math.floats
 
 HELP: float
@@ -48,42 +48,42 @@ HELP: float/f
 { $warning "This word does not perform type checking, and passing objects of the wrong type can crash the runtime. User code should call the generic word " { $link /f } " instead." } ;
 
 HELP: float<
-{ $values { "x" float } { "y" float } { "?" "a boolean" } }
+{ $values { "x" float } { "y" float } { "?" boolean } }
 { $description "Primitive version of " { $link < } "." }
 { $warning "This word does not perform type checking, and passing objects of the wrong type can crash the runtime. User code should call the generic word " { $link < } " instead." } ;
 
 HELP: float<=
-{ $values { "x" float } { "y" float } { "?" "a boolean" } }
+{ $values { "x" float } { "y" float } { "?" boolean } }
 { $description "Primitive version of " { $link <= } "." }
 { $warning "This word does not perform type checking, and passing objects of the wrong type can crash the runtime. User code should call the generic word " { $link <= } " instead." } ;
 
 HELP: float>
-{ $values { "x" float } { "y" float } { "?" "a boolean" } }
+{ $values { "x" float } { "y" float } { "?" boolean } }
 { $description "Primitive version of " { $link > } "." }
 { $warning "This word does not perform type checking, and passing objects of the wrong type can crash the runtime. User code should call the generic word " { $link > } " instead." } ;
 
 HELP: float>=
-{ $values { "x" float } { "y" float } { "?" "a boolean" } }
+{ $values { "x" float } { "y" float } { "?" boolean } }
 { $description "Primitive version of " { $link u>= } "." }
 { $warning "This word does not perform type checking, and passing objects of the wrong type can crash the runtime. User code should call the generic word " { $link u>= } " instead." } ;
 
 HELP: float-u<
-{ $values { "x" float } { "y" float } { "?" "a boolean" } }
+{ $values { "x" float } { "y" float } { "?" boolean } }
 { $description "Primitive version of " { $link u< } "." }
 { $warning "This word does not perform type checking, and passing objects of the wrong type can crash the runtime. User code should call the generic word " { $link u< } " instead." } ;
 
 HELP: float-u<=
-{ $values { "x" float } { "y" float } { "?" "a boolean" } }
+{ $values { "x" float } { "y" float } { "?" boolean } }
 { $description "Primitive version of " { $link u<= } "." }
 { $warning "This word does not perform type checking, and passing objects of the wrong type can crash the runtime. User code should call the generic word " { $link u<= } " instead." } ;
 
 HELP: float-u>
-{ $values { "x" float } { "y" float } { "?" "a boolean" } }
+{ $values { "x" float } { "y" float } { "?" boolean } }
 { $description "Primitive version of " { $link u> } "." }
 { $warning "This word does not perform type checking, and passing objects of the wrong type can crash the runtime. User code should call the generic word " { $link u> } " instead." } ;
 
 HELP: float-u>=
-{ $values { "x" float } { "y" float } { "?" "a boolean" } }
+{ $values { "x" float } { "y" float } { "?" boolean } }
 { $description "Primitive version of " { $link u>= } "." }
 { $warning "This word does not perform type checking, and passing objects of the wrong type can crash the runtime. User code should call the generic word " { $link u>= } " instead." } ;
 
index 1a004c832fd87ca87937fcff0400b0464826baae..a7cc1cee821b6e6801c449cb8825f2a72e23402b 100644 (file)
@@ -1,4 +1,4 @@
-USING: help.markup help.syntax math math.private ;
+USING: help.markup help.syntax kernel math math.private ;
 IN: math.integers
 
 ARTICLE: "integers" "Integers"
@@ -44,11 +44,11 @@ HELP: integer
 { $class-description "The class of integers, which is a disjoint union of fixnums and bignums." } ;
 
 HELP: even?
-{ $values { "n" integer } { "?" "a boolean" } }
+{ $values { "n" integer } { "?" boolean } }
 { $description "Tests if an integer is even." } ;
 
 HELP: odd?
-{ $values { "n" integer } { "?" "a boolean" } }
+{ $values { "n" integer } { "?" boolean } }
 { $description "Tests if an integer is odd." } ;
 
 ! Unsafe primitives
@@ -83,7 +83,7 @@ HELP: fixnum/mod
 { $warning "This word does not perform type checking, and passing objects of the wrong type can crash the runtime. User code should call the generic word " { $link /mod } " instead." } ;
 
 HELP: fixnum<
-{ $values { "x" fixnum } { "y" fixnum } { "?" "a boolean" } }
+{ $values { "x" fixnum } { "y" fixnum } { "?" boolean } }
 { $description "Primitive version of " { $link < } "." }
 { $warning "This word does not perform type checking, and passing objects of the wrong type can crash the runtime. User code should call the generic word " { $link < } " instead." } ;
 
@@ -93,12 +93,12 @@ HELP: fixnum<=
 { $warning "This word does not perform type checking, and passing objects of the wrong type can crash the runtime. User code should call the generic word " { $link <= } " instead." } ;
 
 HELP: fixnum>
-{ $values { "x" fixnum } { "y" fixnum } { "?" "a boolean" } }
+{ $values { "x" fixnum } { "y" fixnum } { "?" boolean } }
 { $description "Primitive version of " { $link > } "." }
 { $warning "This word does not perform type checking, and passing objects of the wrong type can crash the runtime. User code should call the generic word " { $link > } " instead." } ;
 
 HELP: fixnum>=
-{ $values { "x" fixnum } { "y" fixnum } { "?" "a boolean" } }
+{ $values { "x" fixnum } { "y" fixnum } { "?" boolean } }
 { $description "Primitive version of " { $link >= } "." }
 { $warning "This word does not perform type checking, and passing objects of the wrong type can crash the runtime. User code should call the generic word " { $link >= } " instead." } ;
 
@@ -178,27 +178,27 @@ HELP: bignum/mod
 { $warning "This word does not perform type checking, and passing objects of the wrong type can crash the runtime. User code should call the generic word " { $link /mod } " instead." } ;
 
 HELP: bignum<
-{ $values { "x" bignum } { "y" bignum } { "?" "a boolean" } }
+{ $values { "x" bignum } { "y" bignum } { "?" boolean } }
 { $description "Primitive version of " { $link < } "." }
 { $warning "This word does not perform type checking, and passing objects of the wrong type can crash the runtime. User code should call the generic word " { $link < } " instead." } ;
 
 HELP: bignum<=
-{ $values { "x" bignum } { "y" bignum } { "?" "a boolean" } }
+{ $values { "x" bignum } { "y" bignum } { "?" boolean } }
 { $description "Primitive version of " { $link <= } "." }
 { $warning "This word does not perform type checking, and passing objects of the wrong type can crash the runtime. User code should call the generic word " { $link <= } " instead." } ;
 
 HELP: bignum>
-{ $values { "x" bignum } { "y" bignum } { "?" "a boolean" } }
+{ $values { "x" bignum } { "y" bignum } { "?" boolean } }
 { $description "Primitive version of " { $link > } "." }
 { $warning "This word does not perform type checking, and passing objects of the wrong type can crash the runtime. User code should call the generic word " { $link > } " instead." } ;
 
 HELP: bignum>=
-{ $values { "x" bignum } { "y" bignum } { "?" "a boolean" } }
+{ $values { "x" bignum } { "y" bignum } { "?" boolean } }
 { $description "Primitive version of " { $link >= } "." }
 { $warning "This word does not perform type checking, and passing objects of the wrong type can crash the runtime. User code should call the generic word " { $link >= } " instead." } ;
 
 HELP: bignum=
-{ $values { "x" bignum } { "y" bignum } { "?" "a boolean" } }
+{ $values { "x" bignum } { "y" bignum } { "?" boolean } }
 { $description "Primitive version of " { $link number= } "." }
 { $warning "This word does not perform type checking, and passing objects of the wrong type can crash the runtime. User code should call the generic word " { $link number= } " instead." } ;
 
index 78a2e626ec51e6a15f4941fd7b5dc5a2ea57cfab..befa11c7e11d291fd28a005888c3028bc072f43c 100644 (file)
@@ -1,9 +1,8 @@
-USING: help.markup help.syntax kernel sequences quotations
-math.private byte-arrays io.binary ;
+USING: help.markup help.syntax kernel quotations sequences ;
 IN: math
 
 HELP: number=
-{ $values { "x" number } { "y" number } { "?" "a boolean" } }
+{ $values { "x" number } { "y" number } { "?" boolean } }
 { $description "Tests if two numbers have the same numeric value." }
 { $notes "This word differs from " { $link = } " in that it disregards differences in type when comparing numbers."
 $nl
@@ -187,7 +186,7 @@ $nl
 "Due to the two's complement representation of signed integers, the following two lines are equivalent:" { $code "bitnot" "neg 1 -" } } ;
 
 HELP: bit?
-{ $values { "x" integer } { "n" integer } { "?" "a boolean" } }
+{ $values { "x" integer } { "n" integer } { "?" boolean } }
 { $description "Tests if the " { $snippet "n" } "th bit of " { $snippet "x" } " is set." }
 { $examples { $example "USING: math prettyprint ;" "0b101 2 bit? ." "t" } } ;
 
@@ -251,7 +250,7 @@ HELP: 2^
 { $description "Computes two to the power of " { $snippet "n" } ". This word will only give correct results if " { $snippet "n" } " is greater than zero; for the general case, use " { $snippet "2 swap ^" } "." } ;
 
 HELP: zero?
-{ $values { "x" number } { "?" "a boolean" } }
+{ $values { "x" number } { "?" boolean } }
 { $description "Tests if the number is equal to zero." } ;
 
 HELP: if-zero
@@ -338,23 +337,23 @@ HELP: fp-bitwise=
 } ;
 
 HELP: fp-special?
-{ $values { "x" real } { "?" "a boolean" } }
+{ $values { "x" real } { "?" boolean } }
 { $description "Tests if " { $snippet "x" } " is an IEEE special value (Not-a-Number or Infinity). While " { $snippet "x" } " can be any real number, this word will only ever yield true if " { $snippet "x" } " is a " { $link float } "." } ;
 
 HELP: fp-nan?
-{ $values { "x" real } { "?" "a boolean" } }
+{ $values { "x" real } { "?" boolean } }
 { $description "Tests if " { $snippet "x" } " is an IEEE Not-a-Number value. While " { $snippet "x" } " can be any real number, this word will only ever yield true if " { $snippet "x" } " is a " { $link float } "." } ;
 
 HELP: fp-qnan?
-{ $values { "x" real } { "?" "a boolean" } }
+{ $values { "x" real } { "?" boolean } }
 { $description "Tests if " { $snippet "x" } " is an IEEE Quiet Not-a-Number value. While " { $snippet "x" } " can be any real number, this word will only ever yield true if " { $snippet "x" } " is a " { $link float } "." } ;
 
 HELP: fp-snan?
-{ $values { "x" real } { "?" "a boolean" } }
+{ $values { "x" real } { "?" boolean } }
 { $description "Tests if " { $snippet "x" } " is an IEEE Signaling Not-a-Number value. While " { $snippet "x" } " can be any real number, this word will only ever yield true if " { $snippet "x" } " is a " { $link float } "." } ;
 
 HELP: fp-infinity?
-{ $values { "x" real } { "?" "a boolean" } }
+{ $values { "x" real } { "?" boolean } }
 { $description "Tests if " { $snippet "x" } " is an IEEE Infinity value. While " { $snippet "x" } " can be any real number, this word will only ever yield true if " { $snippet "x" } " is a " { $link float } "." }
 { $examples
     { $example "USING: math prettyprint ;" "1/0. fp-infinity? ." "t" }
@@ -362,7 +361,7 @@ HELP: fp-infinity?
 } ;
 
 HELP: fp-sign
-{ $values { "x" float } { "?" "a boolean" } }
+{ $values { "x" float } { "?" boolean } }
 { $description "Outputs the sign bit of " { $snippet "x" } ". For ordered non-zero values, this is equivalent to calling " { $snippet "0 <" } ". For zero values, this outputs the zero's sign bit." } ;
 
 HELP: fp-nan-payload
@@ -406,11 +405,11 @@ HELP: number
 { $class-description "The class of numbers." } ;
 
 HELP: next-power-of-2
-{ $values { "m" "a non-negative integer" } { "n" "an integer" } }
+{ $values { "m" "a non-negative integer" } { "n" integer } }
 { $description "Outputs the smallest power of 2 greater than or equal to " { $snippet "m" } ". The output value is always at least 2." } ;
 
 HELP: power-of-2?
-{ $values { "n" integer } { "?" "a boolean" } }
+{ $values { "n" integer } { "?" boolean } }
 { $description "Tests if " { $snippet "n" } " is a power of 2." } ;
 
 HELP: each-integer
@@ -419,7 +418,7 @@ HELP: each-integer
 { $notes "This word is used to implement " { $link each } "." } ;
 
 HELP: all-integers?
-{ $values { "n" integer } { "quot" { $quotation ( ... i -- ... ? ) } } { "?" "a boolean" } }
+{ $values { "n" integer } { "quot" { $quotation ( ... i -- ... ? ) } } { "?" boolean } }
 { $description "Applies the quotation to each integer from 0 up to " { $snippet "n" } ", excluding " { $snippet "n" } ". Iteration stops when the quotation outputs " { $link f } " or the end is reached. If the quotation yields a false value for some integer, this word outputs " { $link f } ". Otherwise, this word outputs " { $link t } "." }
 { $notes "This word is used to implement " { $link all? } "." } ;
 
index 2a0b756c081957d12cda6d9847be2042055e1c86..011dc0bf13c15fb29eab786649d4604ae0e5f7d0 100644 (file)
@@ -1,5 +1,4 @@
-USING: help.markup help.syntax kernel math quotations
-math.private words words.symbol ;
+USING: help.markup help.syntax kernel math ;
 IN: math.order
 
 HELP: <=>
@@ -57,27 +56,27 @@ HELP: clamp
 { $description "Outputs " { $snippet "x" } " if contained in the interval " { $snippet "[min,max]" } " or else outputs one of the endpoints." } ;
 
 HELP: between?
-{ $values { "x" object } { "y" object } { "z" object } { "?" "a boolean" } }
+{ $values { "x" object } { "y" object } { "z" object } { "?" boolean } }
 { $description "Tests if " { $snippet "x" } " is in the interval " { $snippet "[y,z]" } "." }
 { $notes "As per the closed interval notation, the end-points are included in the interval." } ;
 
 HELP: before?
-{ $values { "obj1" object } { "obj2" object } { "?" "a boolean" } }
+{ $values { "obj1" object } { "obj2" object } { "?" boolean } }
 { $description "Tests if " { $snippet "obj1" } " comes before " { $snippet "obj2" } " using an intrinsic total order." }
 { $notes "Implemented using " { $link <=> } "." } ;
 
 HELP: after?
-{ $values { "obj1" object } { "obj2" object } { "?" "a boolean" } }
+{ $values { "obj1" object } { "obj2" object } { "?" boolean } }
 { $description "Tests if " { $snippet "obj1" } " comes after " { $snippet "obj2" } " using an intrinsic total order." }
 { $notes "Implemented using " { $link <=> } "." } ;
 
 HELP: before=?
-{ $values { "obj1" object } { "obj2" object } { "?" "a boolean" } }
+{ $values { "obj1" object } { "obj2" object } { "?" boolean } }
 { $description "Tests if " { $snippet "obj1" } " comes before or equals " { $snippet "obj2" } " using an intrinsic total order." }
 { $notes "Implemented using " { $link <=> } "." } ;
 
 HELP: after=?
-{ $values { "obj1" object } { "obj2" object } { "?" "a boolean" } }
+{ $values { "obj1" object } { "obj2" object } { "?" boolean } }
 { $description "Tests if " { $snippet "obj1" } " comes after or equals " { $snippet "obj2" } " using an intrinsic total order." }
 { $notes "Implemented using " { $link <=> } "." } ;
 
index 7df66997c928f713cc9ae310e428e2d0f19fe1fa..da5fd302cfc50db074522710395e9eb5a10b3256 100644 (file)
@@ -1,8 +1,6 @@
-USING: help.markup help.syntax kernel sequences words
-math strings vectors quotations generic effects classes
-vocabs.loader definitions io vocabs source-files
-namespaces compiler.units assocs lexer
-words.symbol words.alias words.constant vocabs.parser ;
+USING: compiler.units definitions help.markup help.syntax kernel
+lexer math namespaces quotations sequences source-files strings
+vectors vocabs vocabs.parser words words.symbol ;
 IN: parser
 
 ARTICLE: "reading-ahead" "Reading ahead"
@@ -163,7 +161,7 @@ HELP: parse-datum
 { $notes "This word is used to implement " { $link ?scan-datum } " and " { $link scan-datum } "." } ;
 
 HELP: scan-word
-{ $values { "word" "a word" } }
+{ $values { "word" word } }
 { $description "Reads the next token from parser input. If the token is a valid number literal, it is converted to a number, otherwise the vocabulary search path is searched for a word named by the token." }
 { $errors "Throws an error if the token does not name a word or end of file is reached." }
 $parsing-note ;
index 85ea78af839f0509e1c1e5cca74f0c2170c241f9..7a129d571c66722a1e10381f6f1cafad9c5f1f47 100644 (file)
@@ -1,6 +1,5 @@
-USING: arrays help.markup help.syntax math
-sequences.private vectors strings kernel math.order layouts
-quotations generic.single ;
+USING: arrays generic.single help.markup help.syntax kernel
+layouts math math.order quotations sequences.private vectors ;
 IN: sequences
 
 HELP: sequence
@@ -77,7 +76,7 @@ $nl
 { $notes "Unlike " { $link clone-like } ", the output sequence might share storage with the input sequence." } ;
 
 HELP: empty?
-{ $values { "seq" sequence } { "?" "a boolean" } }
+{ $values { "seq" sequence } { "?" boolean } }
 { $description "Tests if the sequence has zero length." } ;
 
 HELP: if-empty
@@ -163,7 +162,7 @@ HELP: push
 { $side-effects "seq" } ;
 
 HELP: bounds-check?
-{ $values { "n" "an integer" } { "seq" sequence } { "?" "a boolean" } }
+{ $values { "n" integer } { "seq" sequence } { "?" boolean } }
 { $description "Tests if the index is within the bounds of the sequence." } ;
 
 HELP: bounds-error
@@ -176,11 +175,11 @@ HELP: bounds-check
 { $description "Throws an error if " { $snippet "n" } " is negative or if it is greater than or equal to the length of " { $snippet "seq" } ". Otherwise the two inputs remain on the stack." } ;
 
 HELP: ?nth
-{ $values { "n" "an integer" } { "seq" sequence } { "elt/f" "an object or " { $link f } } }
+{ $values { "n" integer } { "seq" sequence } { "elt/f" "an object or " { $link f } } }
 { $description "A forgiving version of " { $link nth } ". If the index is out of bounds, or if the sequence is " { $link f } ", simply outputs " { $link f } "." } ;
 
 HELP: ?set-nth
-{ $values { "elt" object } { "n" "an integer" } { "seq" sequence } }
+{ $values { "elt" object } { "n" integer } { "seq" sequence } }
 { $description "A forgiving version of " { $link set-nth } ".  If the index is out of bounds, does nothing." } ;
 
 HELP: ?first
@@ -209,11 +208,11 @@ HELP: ?last
 { $description "A forgiving version of " { $link last } ". If the sequence is empty, or if the sequence is " { $link f } ", simply outputs " { $link f } "." } ;
 
 HELP: nth-unsafe
-{ $values { "n" "an integer" } { "seq" sequence } { "elt" object } }
+{ $values { "n" integer } { "seq" sequence } { "elt" object } }
 { $contract "Unsafe variant of " { $link nth } " that does not perform bounds checks." } ;
 
 HELP: set-nth-unsafe
-{ $values { "elt" object } { "n" "an integer" } { "seq" sequence } }
+{ $values { "elt" object } { "n" integer } { "seq" sequence } }
 { $contract "Unsafe variant of " { $link set-nth } " that does not perform bounds checks." } ;
 
 HELP: exchange-unsafe
@@ -428,7 +427,7 @@ HELP: 3map-as
 { $description "Applies the quotation to each triple of elements in turn, yielding new elements which are collected into a new sequence having the same class as " { $snippet "exemplar" } "." } ;
 
 HELP: 2all?
-{ $values { "seq1" sequence } { "seq2" sequence } { "quot" { $quotation ( ... elt1 elt2 -- ... ? ) } } { "?" "a boolean" } }
+{ $values { "seq1" sequence } { "seq2" sequence } { "quot" { $quotation ( ... elt1 elt2 -- ... ? ) } } { "?" boolean } }
 { $description "Tests the predicate pairwise against elements of " { $snippet "seq1" } " and " { $snippet "seq2" } "." } ;
 
 HELP: find
@@ -474,11 +473,11 @@ HELP: map-find
 { $description "Applies the quotation to each element of the sequence, until the quotation outputs a true value. If the quotation ever yields a result which is not " { $link f } ", then the value is output, along with the element of the sequence which yielded this." } ;
 
 HELP: any?
-{ $values { "seq" sequence } { "quot" { $quotation ( ... elt -- ... ? ) } } { "?" "a boolean" } }
+{ $values { "seq" sequence } { "quot" { $quotation ( ... elt -- ... ? ) } } { "?" boolean } }
 { $description "Tests if the sequence contains an element satisfying the predicate, by applying the predicate to each element in turn until a true value is found. If the sequence is empty or if the end of the sequence is reached, outputs " { $link f } "." } ;
 
 HELP: all?
-{ $values { "seq" sequence } { "quot" { $quotation ( ... elt -- ... ? ) } } { "?" "a boolean" } }
+{ $values { "seq" sequence } { "quot" { $quotation ( ... elt -- ... ? ) } } { "?" boolean } }
 { $description "Tests if all elements in the sequence satisfy the predicate by checking each element in turn. Given an empty sequence, vacuously outputs " { $link t } "." } ;
 
 HELP: push-if
@@ -500,7 +499,7 @@ HELP: filter!
 { $side-effects "seq" } ;
 
 HELP: interleave
-{ $values { "seq" sequence } { "between" "a quotation" } { "quot" { $quotation ( ... elt -- ... ) } } }
+{ $values { "seq" sequence } { "between" quotation } { "quot" { $quotation ( ... elt -- ... ) } } }
 { $description "Applies " { $snippet "quot" } " to each element in turn, also invoking " { $snippet "between" } " in-between each pair of elements." }
 { $examples { $example "USING: io sequences ;" "{ \"a\" \"b\" \"c\" } [ \"X\" write ] [ write ] interleave" "aXbXc" } } ;
 
@@ -521,12 +520,12 @@ HELP: last-index-from
 { $description "Outputs the index of the last element in the sequence equal to " { $snippet "obj" } ", traversing the sequence backwards starting from the " { $snippet "i" } "th element and finishing at the first. If no element is found, outputs " { $link f } "." } ;
 
 HELP: member?
-{ $values { "elt" object } { "seq" sequence } { "?" "a boolean" } }
+{ $values { "elt" object } { "seq" sequence } { "?" boolean } }
 { $description "Tests if the sequence contains an element equal to the object." }
 { $notes "This word uses equality comparison (" { $link = } ")." } ;
 
 HELP: member-eq?
-{ $values { "elt" object } { "seq" sequence } { "?" "a boolean" } }
+{ $values { "elt" object } { "seq" sequence } { "?" boolean } }
 { $description "Tests if the sequence contains the object." }
 { $notes "This word uses identity comparison (" { $link eq? } ")." } ;
 
@@ -695,7 +694,7 @@ HELP: pad-tail
 { $examples { $example "USING: io sequences ;" "{ \"ab\" \"quux\" } [ 5 CHAR: - pad-tail print ] each" "ab---\nquux-" } } ;
 
 HELP: sequence=
-{ $values { "seq1" sequence } { "seq2" sequence } { "?" "a boolean" } }
+{ $values { "seq1" sequence } { "seq2" sequence } { "?" boolean } }
 { $description "Tests if the two sequences have the same length and elements. This is weaker than " { $link = } ", since it does not ensure that the sequences are instances of the same class." } ;
 
 HELP: reversed
@@ -947,11 +946,11 @@ HELP: tail*
 { $errors "Throws an error if the index is out of bounds." } ;
 
 HELP: shorter?
-{ $values { "seq1" sequence } { "seq2" sequence } { "?" "a boolean" } }
+{ $values { "seq1" sequence } { "seq2" sequence } { "?" boolean } }
 { $description "Tests if the length of " { $snippet "seq1" } " is smaller than the length of " { $snippet "seq2" } "." } ;
 
 HELP: head?
-{ $values { "seq" sequence } { "begin" sequence } { "?" "a boolean" } }
+{ $values { "seq" sequence } { "begin" sequence } { "?" boolean } }
 { $description "Tests if " { $snippet "seq" } " starts with " { $snippet "begin" } ". If " { $snippet "begin" } " is longer than " { $snippet "seq" } ", this word outputs " { $link f } "." }
 { $examples
   { $example
@@ -962,7 +961,7 @@ HELP: head?
 } ;
 
 HELP: tail?
-{ $values { "seq" sequence } { "end" sequence } { "?" "a boolean" } }
+{ $values { "seq" sequence } { "end" sequence } { "?" boolean } }
 { $description "Tests if " { $snippet "seq" } " ends with " { $snippet "end" } ". If " { $snippet "end" } " is longer than " { $snippet "seq" } ", this word outputs " { $link f } "." } ;
 
 { remove remove-nth remove-eq remove-eq! remove! remove-nth! } related-words
@@ -990,7 +989,7 @@ HELP: start
 { $description "Outputs the start index of the first contiguous subsequence equal to " { $snippet "subseq" } ", or " { $link f } " if no matching subsequence is found." } ;
 
 HELP: subseq?
-{ $values { "subseq" sequence } { "seq" sequence } { "?" "a boolean" } }
+{ $values { "subseq" sequence } { "seq" sequence } { "?" boolean } }
 { $description "Tests if " { $snippet "seq" } " contains the elements of " { $snippet "subseq" } " as a contiguous subsequence." } ;
 
 HELP: drop-prefix
index 43d1933d26b0783cf3075cf9ef1d944fe9c0219d..905f20217e60d0c8c40cd74672013acfdbb10143 100644 (file)
@@ -92,7 +92,7 @@ HELP: adjoin
 { $side-effects "set" } ;
 
 HELP: ?adjoin
-{ $values { "elt" object } { "set" set } { "?" "a boolean" } }
+{ $values { "elt" object } { "set" set } { "?" boolean } }
 { $description "A version of " { $link adjoin } " which returns whether the element was added to the set." }
 { $notes "This is slightly less efficient than " { $link adjoin } " due to the initial membership test." } ;
 
@@ -111,7 +111,7 @@ HELP: members
 { $description "Creates a sequence with a single copy of each member of the set." $nl "Each set type is expected to implement a method on this generic word." } ;
 
 HELP: in?
-{ $values { "elt" object } { "set" set } { "?" "a boolean" } }
+{ $values { "elt" object } { "set" set } { "?" boolean } }
 { $description "Tests whether the element is a member of the set." $nl "Each set type is expected to implement a method on this generic word as part of the set protocol." } ;
 
 HELP: adjoin-at
@@ -127,7 +127,7 @@ HELP: duplicates
 } ;
 
 HELP: all-unique?
-{ $values { "set" set } { "?" "a boolean" } }
+{ $values { "set" set } { "?" boolean } }
 { $description "Tests whether a set contains any repeated elements." }
 { $example
     "USING: sets prettyprint ;"
@@ -151,7 +151,7 @@ HELP: intersect
 } ;
 
 HELP: intersection
-{ $values { "sets" sequence } { "set/f" "a " { $link set } " or " { $link f } } }
+{ $values { "sets" sequence } { "set/f" { $maybe set } } }
 { $description "Outputs the intersection of all the sets of the sequence " { $snippet "sets" } ", or " { $link f } " if " { $snippet "sets" } " is empty." } ;
 
 HELP: union
@@ -179,17 +179,17 @@ HELP: intersect!
 { $side-effects "set1" } ;
 
 HELP: intersects?
-{ $values { "set1" set } { "set2" set } { "?" "a boolean" } }
+{ $values { "set1" set } { "set2" set } { "?" boolean } }
 { $description "Tests if " { $snippet "set1" } " and " { $snippet "set2" } " have any elements in common." }
 { $notes "If one of the sets is empty, the result is always " { $link f } "." } ;
 
 HELP: subset?
-{ $values { "set1" set } { "set2" set } { "?" "a boolean" } }
+{ $values { "set1" set } { "set2" set } { "?" boolean } }
 { $description "Tests if every element of " { $snippet "set1" } " is contained in " { $snippet "set2" } "." }
 { $notes "If " { $snippet "set1" } " is empty, the result is always " { $link t } "." } ;
 
 HELP: set=
-{ $values { "set1" set } { "set2" set } { "?" "a boolean" } }
+{ $values { "set1" set } { "set2" set } { "?" boolean } }
 { $description "Tests if both sets contain the same elements, disregrading order and duplicates." } ;
 
 HELP: gather
@@ -214,7 +214,7 @@ HELP: without
 { $description "Returns the subsequence of the given sequence consisting of things that are not members of the set. This may contain duplicates, if the sequence has duplicates." } ;
 
 HELP: null?
-{ $values { "set" set } { "?" "a boolean" } }
+{ $values { "set" set } { "?" boolean } }
 { $description "Tests whether the given set is empty. This outputs " { $snippet "t" } " when given a null set of any type." } ;
 
 HELP: cardinality
@@ -222,5 +222,5 @@ HELP: cardinality
 { $description "Returns the number of elements in the set. All sets support this operation." } ;
 
 HELP: combine
-{ $values { "sets" "a sequence of sets" } { "set/f" "a " { $link set } " or " { $link f } } }
+{ $values { "sets" "a sequence of sets" } { "set/f" { $maybe set } } }
 { $description "Outputs the union of a sequence of sets, or " { $link f } " if the sequence is empty." } ;
index d1a2c6fd800e1ed1b47b5fa384ee4a1f6caaf0ce..92c5cb8636457bb36f85a5a7d964ca3185151334 100644 (file)
@@ -1,4 +1,4 @@
-USING: help.markup help.syntax sequences strings ;
+USING: help.markup help.syntax kernel sequences strings ;
 IN: splitting
 
 ARTICLE: "sequences-split" "Splitting sequences"
@@ -66,19 +66,19 @@ HELP: split
 { $examples { $example "USING: prettyprint splitting ;" "\"hello world-how are you?\" \" -\" split ." "{ \"hello\" \"world\" \"how\" \"are\" \"you?\" }" } } ;
 
 HELP: ?head
-{ $values { "seq" sequence } { "begin" sequence } { "newseq" "a new sequence" } { "?" "a boolean" } }
+{ $values { "seq" sequence } { "begin" sequence } { "newseq" "a new sequence" } { "?" boolean } }
 { $description "Tests if " { $snippet "seq" } " starts with " { $snippet "begin" } ". If there is a match, outputs the subrange of " { $snippet "seq" } " excluding " { $snippet "begin" } ", and " { $link t } ". If there is no match, outputs " { $snippet "seq" } " and " { $link f } "." } ;
 
 HELP: ?head-slice
-{ $values { "seq" sequence } { "begin" sequence } { "newseq" slice } { "?" "a boolean" } }
+{ $values { "seq" sequence } { "begin" sequence } { "newseq" slice } { "?" boolean } }
 { $description "Like " { $link ?head } ", except the resulting sequence is a " { $link slice } "." } ;
 
 HELP: ?tail
-{ $values { "seq" sequence } { "end" sequence } { "newseq" "a new sequence" } { "?" "a boolean" } }
+{ $values { "seq" sequence } { "end" sequence } { "newseq" "a new sequence" } { "?" boolean } }
 { $description "Tests if " { $snippet "seq" } " ends with " { $snippet "end" } ". If there is a match, outputs the subrange of " { $snippet "seq" } " excluding " { $snippet "end" } ", and " { $link t } ". If there is no match, outputs " { $snippet "seq" } " and " { $link f } "." } ;
 
 HELP: ?tail-slice
-{ $values { "seq" sequence } { "end" sequence } { "newseq" slice } { "?" "a boolean" } }
+{ $values { "seq" sequence } { "end" sequence } { "newseq" slice } { "?" boolean } }
 { $description "Like " { $link ?tail } ", except the resulting sequence is a " { $link slice } "." } ;
 
 HELP: string-lines
index 708d9da67b5b0d25cc966323ee99af580c5cf8ac..e3e221feb3abfa010a5b50b5f2b1cfe9d53ba604 100644 (file)
@@ -1,7 +1,8 @@
-USING: generic help.syntax help.markup kernel math parser words
-effects classes classes.tuple generic.math generic.single arrays
-io.pathnames vocabs.loader io sequences assocs words.symbol
-words.alias words.constant combinators vocabs.parser command-line ;
+USING: arrays assocs classes.tuple combinators command-line
+effects generic generic.math generic.single help.markup
+help.syntax io.pathnames kernel math parser sequences
+vocabs.loader vocabs.parser words words.alias words.constant
+words.symbol ;
 IN: syntax
 
 ARTICLE: "parser-algorithm" "Parser algorithm"
@@ -411,7 +412,7 @@ HELP: W{
 
 HELP: POSTPONE:
 { $syntax "POSTPONE: word" }
-{ $values { "word" "a word" } }
+{ $values { "word" word } }
 { $description "Reads the next word from the input string and appends the word to the parse tree, even if it is a parsing word." }
 { $examples "For an ordinary word " { $snippet "foo" } ", " { $snippet "foo" } " and " { $snippet "POSTPONE: foo" } " are equivalent; however, if " { $snippet "foo" } " is a parsing word, the former will execute it at parse time, while the latter will execute it at runtime." }
 { $notes "This word is used inside parsing words to delegate further action to another parsing word, and to refer to parsing words literally from literal arrays and such." } ;
@@ -488,7 +489,7 @@ HELP: CONSTANT:
 
 HELP: \
 { $syntax "\\ word" }
-{ $values { "word" "a word" } }
+{ $values { "word" word } }
 { $description "Reads the next word from the input and appends a wrapper holding the word to the parse tree. When the evaluator encounters a wrapper, it pushes the wrapped word literally on the data stack." }
 { $examples "The following two lines are equivalent:" { $code "0 \\ <vector> execute\n0 <vector>" } "If " { $snippet "foo" } " is a symbol, the following two lines are equivalent:" { $code "foo" "\\ foo" } } ;
 
@@ -501,7 +502,7 @@ HELP: DEFER:
 
 HELP: FORGET:
 { $syntax "FORGET: word" }
-{ $values { "word" "a word" } }
+{ $values { "word" word } }
 { $description "Removes the word from its vocabulary, or does nothing if no such word exists. Existing definitions that reference forgotten words will continue to work, but new occurrences of the word will not parse." } ;
 
 HELP: USE:
index 7efee3d60aaf1f3e16bd99a13318a0eda49f0500..3e8c0b4fcc976aa619af597c43f89255f87d6ec8 100644 (file)
@@ -1,5 +1,4 @@
-USING: generic help.markup help.syntax kernel math memory
-namespaces sequences kernel.private strings classes.singleton ;
+USING: classes.singleton help.markup help.syntax kernel math ;
 IN: system
 
 ABOUT: "system"
@@ -61,7 +60,7 @@ HELP: os
 } ;
 
 HELP: embedded?
-{ $values { "?" "a boolean" } }
+{ $values { "?" boolean } }
 { $description "Tests if this Factor instance is embedded in another application." } ;
 
 HELP: exit
index 55390ec0e174a64d8e53d89d48647cb9ed4b9ad2..4006706ffc47ca606324b25a237e0856b4ae281a 100644 (file)
@@ -1,6 +1,5 @@
-USING: definitions help.markup help.syntax kernel parser
-kernel.private vocabs classes quotations sequences
-strings effects compiler.units ;
+USING: classes compiler.units definitions effects help.markup
+help.syntax kernel parser quotations sequences strings vocabs ;
 IN: words
 
 ARTICLE: "interned-words" "Looking up and creating words"
@@ -316,7 +315,7 @@ HELP: bootstrap-word
 { $description "Looks up a word with the same name and vocabulary as the given word, performing a transformation to handle parsing words in the target dictionary. Used during bootstrap to transfer host words to the target dictionary." } ;
 
 HELP: parsing-word?
-{ $values { "object" object } { "?" "a boolean" } }
+{ $values { "object" object } { "?" boolean } }
 { $description "Tests if an object is a parsing word declared by " { $link POSTPONE: SYNTAX: } "." }
 { $notes "Outputs " { $link f } " if the object is not a word." } ;
 
@@ -337,12 +336,12 @@ HELP: define-temp
 } ;
 
 HELP: delimiter?
-{ $values { "obj" object } { "?" "a boolean" } }
+{ $values { "obj" object } { "?" boolean } }
 { $description "Tests if an object is a delimiter word declared by " { $link POSTPONE: delimiter } "." }
 { $notes "Outputs " { $link f } " if the object is not a word." } ;
 
 HELP: deprecated?
-{ $values { "obj" object } { "?" "a boolean" } }
+{ $values { "obj" object } { "?" boolean } }
 { $description "Tests if an object is " { $link POSTPONE: deprecated } "." }
 { $notes "Outputs " { $link f } " if the object is not a word." } ;