]> gitweb.factorcode.org Git - factor.git/commitdiff
tools.deploy.shaker: clear MEMO: caches
authorJoe Groff <arcata@gmail.com>
Wed, 14 Dec 2011 20:44:40 +0000 (12:44 -0800)
committerJoe Groff <arcata@gmail.com>
Wed, 14 Dec 2011 20:44:40 +0000 (12:44 -0800)
basis/tools/deploy/shaker/shaker.factor

index cf53e47b63f24f7c18e0f67399bdf74a33056725..f6e280870f2beeb14f24e1ac114e3492312e36bd 100755 (executable)
@@ -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 -- * )