Handbook
Glossary
strip-globals ( -- )
Vocabulary
tools
.
deploy
.
shaker
Inputs
None
Outputs
None
Definition
USING:
accessors
assocs
hashtables
io.streams.c
kernel
locals.backend
namespaces
tools.deploy.config
;
IN:
tools.deploy.shaker
:
strip-globals
( -- )
strip-globals?
[
"Stripping globals"
show
stripped-globals
load-local
cleared-globals
load-local
global
boxes>>
-1
get-local
[
load-local
drop
0
get-local
strip-global?
1
drop-locals
]
curry
assoc-reject!
0
get-local
[
load-local
0
get-local
[
load-local
swap
0
get-local
clear-global?
[
f
swap
value<<
]
[
drop
]
if
1
drop-locals
]
curry
assoc-each
1
drop-locals
]
curry
[
rehash
]
bi
2
drop-locals
]
when
;