1 USING: generic kernel kernel.private math memory prettyprint io
2 sequences tools.test words namespaces layouts classes
3 classes.builtin arrays quotations io.launcher system ;
6 [ ] [ { } { } become ] unit-test
13 "-e=USING: memory io prettyprint system ; input-stream gc . 0 exit"
17 [ [ ] instances ] must-infer
19 ! Code GC wasn't kicking in when needed
20 : leak-step ( -- ) 800000 f <array> 1quotation call( -- obj ) drop ;
22 : leak-loop ( -- ) 100 [ leak-step ] times ;
24 [ ] [ leak-loop ] unit-test
26 TUPLE: testing x y z ;
28 [ save-image-and-exit ] must-fail
31 2 [ [ [ 3 throw ] instances ] must-fail ] times
33 ! Bug found on Windows build box, having too many words in the image breaks 'become'
34 [ ] [ 100000 [ f f <word> ] replicate { } { } become drop ] unit-test