Handbook
Glossary
define-memoized ( word quot effect -- )
Factor handbook
»
The language
»
Memoization
Prev:
MEMO:
Next:
reset-memoized ( word -- )
Vocabulary
memoize
Inputs
word
a
word
quot
a
quotation
effect
an
effect
Outputs
None
Word description
Defines the given word at run time as one which memoizes its outputs given a particular input.
See also
MEMO:
Definition
USING:
kernel
memoize.private
;
IN:
memoize
:
define-memoized
( word quot effect -- )
dup
memo-cache
(define-memoized)
;