factor/basis/memoize/memoize-docs.factor

17 lines
819 B
Factor
Raw Normal View History

! Copyright (C) 2007, 2009 Slava Pestov, Daniel Ehrenberg.
2007-09-20 18:09:08 -04:00
! See http://factorcode.org/license.txt for BSD license.
USING: help.syntax help.markup words quotations effects ;
2008-01-06 22:36:34 -05:00
IN: memoize
2007-09-20 18:09:08 -04:00
HELP: define-memoized
{ $values { "word" word } { "quot" quotation } { "effect" effect } }
2007-09-20 18:09:08 -04:00
{ $description "defines the given word at runtime as one which memoizes its output given a particular input" }
{ $notes "A maximum of four input and four output arguments can be used" }
{ $see-also POSTPONE: MEMO: } ;
HELP: MEMO:
{ $syntax "MEMO: word ( stack -- effect ) definition ;" }
{ $description "defines the given word at parsetime as one which memoizes its output given a particular input. The stack effect is mandatory." }
{ $notes "A maximum of four input and four output arguments can be used" }
{ $see-also define-memoized } ;