From 5557574e1c5f5512267aed580fbd7c60d18d7859 Mon Sep 17 00:00:00 2001 From: Joe Groff Date: Wed, 14 Dec 2011 12:44:40 -0800 Subject: [PATCH] tools.deploy.shaker: clear MEMO: caches --- basis/tools/deploy/shaker/shaker.factor | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/basis/tools/deploy/shaker/shaker.factor b/basis/tools/deploy/shaker/shaker.factor index cf53e47b63..f6e280870f 100755 --- a/basis/tools/deploy/shaker/shaker.factor +++ b/basis/tools/deploy/shaker/shaker.factor @@ -9,7 +9,7 @@ sets vectors quotations byte-arrays sorting compiler.units definitions generic generic.standard generic.single tools.deploy.config combinators combinators.private classes vocabs.loader.private classes.builtin slots.private grouping -command-line io.pathnames namespaces.private ; +command-line io.pathnames memoize namespaces.private ; QUALIFIED: bootstrap.stage2 QUALIFIED: classes.private QUALIFIED: compiler.crossref @@ -237,6 +237,10 @@ IN: tools.deploy.shaker strip-word-names? [ dup strip-word-names strip-stack-traces ] when 2drop ; +: strip-memoized ( -- ) + "Clearing memoized word caches" show + [ memoized? ] instances [ reset-memoized ] each ; + : compiler-classes ( -- seq ) { "compiler" "stack-checker" } [ child-vocabs [ words ] map concat [ class? ] filter ] @@ -565,6 +569,7 @@ SYMBOL: deploy-vocab compress-objects compress-quotations strip-words + strip-memoized clear-megamorphic-caches ; : die-with ( error original-error -- * )