remove math.blas.syntax and merge parsing words into math.blas.vectors/matrices
[factor/jcg.git] / basis / compiler / tests / redefine10.factor
blob8a6fb8a313e93a8c6ba82f7aee305462b0a563a5
1 USING: eval tools.test compiler.units vocabs multiline words
2 kernel ;
3 IN: compiler.tests
5 ! Mixin redefinition did not recompile all necessary words.
7 [ ] [ [ "compiler.tests.redefine10" forget-vocab ] with-compilation-unit ] unit-test
9 [ ] [
10     <"
11     USING: kernel math classes ;
12     IN: compiler.tests.redefine10
13     MIXIN: my-mixin
14     INSTANCE: fixnum my-mixin
15     : my-inline ( a -- b ) dup my-mixin instance? [ 1 + ] when ;
16     "> eval
17 ] unit-test
19 [ ] [
20     <"
21     USE: math
22     IN: compiler.tests.redefine10
23     INSTANCE: float my-mixin
24     "> eval
25 ] unit-test
27 [ 2.0 ] [
28     1.0 "my-inline" "compiler.tests.redefine10" lookup execute
29 ] unit-test