diff --git a/core/arrays/arrays-tests.factor b/core/arrays/arrays-tests.factor index a7801c7d74..ce56b4c506 100755 --- a/core/arrays/arrays-tests.factor +++ b/core/arrays/arrays-tests.factor @@ -1,4 +1,4 @@ -USING: arrays kernel sequences sequences.private growable +USING: accessors arrays kernel sequences sequences.private growable tools.test vectors layouts system math vectors.private ; IN: arrays.tests @@ -11,7 +11,7 @@ IN: arrays.tests [ V{ "a" "b" "c" } ] [ { "a" "b" "c" } >vector ] unit-test [ f ] [ { "a" "b" "c" } dup >array eq? ] unit-test [ t ] [ { "a" "b" "c" } dup { } like eq? ] unit-test -[ t ] [ { "a" "b" "c" } dup dup length array>vector underlying eq? ] unit-test +[ t ] [ { "a" "b" "c" } dup dup length array>vector underlying>> eq? ] unit-test [ V{ "a" "b" "c" } ] [ { "a" "b" "c" } V{ } like ] unit-test [ { "a" "b" "c" } ] [ { "a" } { "b" "c" } append ] unit-test [ { "a" "b" "c" "d" "e" } ] diff --git a/core/compiler/tests/intrinsics.factor b/core/compiler/tests/intrinsics.factor index 3582ee71a1..8d2e84bc65 100755 --- a/core/compiler/tests/intrinsics.factor +++ b/core/compiler/tests/intrinsics.factor @@ -1,4 +1,4 @@ -USING: arrays compiler.units kernel kernel.private math +USING: accessors arrays compiler.units kernel kernel.private math math.constants math.private sequences strings tools.test words continuations sequences.private hashtables.private byte-arrays strings.private system random layouts vectors.private diff --git a/core/compiler/tests/redefine1.factor b/core/compiler/tests/redefine1.factor index 38929d1282..d448d031b9 100644 --- a/core/compiler/tests/redefine1.factor +++ b/core/compiler/tests/redefine1.factor @@ -1,7 +1,7 @@ IN: compiler.tests -USING: compiler compiler.units tools.test math parser kernel -sequences sequences.private classes.mixin generic definitions -arrays words assocs ; +USING: accessors compiler compiler.units tools.test math parser +kernel sequences sequences.private classes.mixin generic +definitions arrays words assocs ; GENERIC: method-redefine-test ( a -- b ) diff --git a/core/compiler/tests/redefine3.factor b/core/compiler/tests/redefine3.factor index 9f839399a8..f7175aac55 100644 --- a/core/compiler/tests/redefine3.factor +++ b/core/compiler/tests/redefine3.factor @@ -1,7 +1,7 @@ IN: compiler.tests -USING: compiler compiler.units tools.test math parser kernel -sequences sequences.private classes.mixin generic definitions -arrays words assocs ; +USING: accessors compiler compiler.units tools.test math parser +kernel sequences sequences.private classes.mixin generic +definitions arrays words assocs ; GENERIC: sheeple ( obj -- x ) diff --git a/core/compiler/tests/simple.factor b/core/compiler/tests/simple.factor index f3e29a6284..272f92ec07 100755 --- a/core/compiler/tests/simple.factor +++ b/core/compiler/tests/simple.factor @@ -235,6 +235,6 @@ M: f single-combination-test-2 single-combination-test-4 ; 10 [ [ "compiler.tests.foo" forget-vocab ] with-compilation-unit [ t ] [ - "USING: prettyprint words ; IN: compiler.tests.foo : (recursive) ( -- ) (recursive) (recursive) ; inline : recursive ( -- ) (recursive) ; \\ (recursive) compiled>>" eval + "USING: prettyprint words accessors ; IN: compiler.tests.foo : (recursive) ( -- ) (recursive) (recursive) ; inline : recursive ( -- ) (recursive) ; \\ (recursive) compiled>>" eval ] unit-test ] times diff --git a/core/compiler/tests/templates.factor b/core/compiler/tests/templates.factor index 760a0036bc..c8baaea164 100755 --- a/core/compiler/tests/templates.factor +++ b/core/compiler/tests/templates.factor @@ -1,5 +1,5 @@ ! Black box testing of templating optimization -USING: arrays compiler kernel kernel.private math +USING: accessors arrays compiler kernel kernel.private math hashtables.private math.private namespaces sequences sequences.private tools.test namespaces.private slots.private sequences.private byte-arrays alien alien.accessors layouts @@ -138,7 +138,7 @@ unit-test 0 swap hellish-bug-2 drop ; [ ] [ - H{ { 1 2 } { 3 4 } } dup hash-array + H{ { 1 2 } { 3 4 } } dup array>> [ 0 swap hellish-bug-2 drop ] compile-call ] unit-test diff --git a/core/cpu/x86/intrinsics/intrinsics.factor b/core/cpu/x86/intrinsics/intrinsics.factor index 03668cea3d..38adedc6b6 100755 --- a/core/cpu/x86/intrinsics/intrinsics.factor +++ b/core/cpu/x86/intrinsics/intrinsics.factor @@ -83,12 +83,14 @@ IN: cpu.x86.intrinsics { [ %slot-literal-known-tag "val" operand MOV generate-write-barrier ] H{ { +input+ { { f "val" } { f "obj" known-tag } { [ small-slot? ] "n" } } } + { +clobber+ { "obj" } } } } ! Slot number is literal { [ %slot-literal-any-tag "val" operand MOV generate-write-barrier ] H{ { +input+ { { f "val" } { f "obj" } { [ small-slot? ] "n" } } } + { +clobber+ { "obj" } } } } ! Slot number in a register diff --git a/core/generic/generic-tests.factor b/core/generic/generic-tests.factor index 5e76f584e3..d41ffaecce 100755 --- a/core/generic/generic-tests.factor +++ b/core/generic/generic-tests.factor @@ -1,4 +1,4 @@ -USING: alien arrays definitions generic generic.standard +USING: accessors alien arrays definitions generic generic.standard generic.math assocs hashtables io kernel math namespaces parser prettyprint sequences strings tools.test vectors words quotations classes classes.algebra continuations layouts diff --git a/core/inference/inference-tests.factor b/core/inference/inference-tests.factor index 3b187dc17e..5ab95c6bc4 100755 --- a/core/inference/inference-tests.factor +++ b/core/inference/inference-tests.factor @@ -1,4 +1,4 @@ -USING: arrays generic inference inference.backend +USING: accessors arrays generic inference inference.backend inference.dataflow kernel classes kernel.private math math.parser math.private namespaces namespaces.private parser sequences strings vectors words quotations effects tools.test diff --git a/core/inference/transforms/transforms-tests.factor b/core/inference/transforms/transforms-tests.factor index a102063c93..b85c8b4600 100755 --- a/core/inference/transforms/transforms-tests.factor +++ b/core/inference/transforms/transforms-tests.factor @@ -51,4 +51,4 @@ C: color [ bad-new-test ] must-infer -[ bad-new-test ] [ T{ not-a-tuple-class f V{ } } = ] must-fail-with +[ bad-new-test ] must-fail diff --git a/core/math/bitfields/bitfields-tests.factor b/core/math/bitfields/bitfields-tests.factor index c1b38011fe..2480012773 100755 --- a/core/math/bitfields/bitfields-tests.factor +++ b/core/math/bitfields/bitfields-tests.factor @@ -1,4 +1,4 @@ -USING: math math.bitfields tools.test kernel words ; +USING: accessors math math.bitfields tools.test kernel words ; IN: math.bitfields.tests [ 0 ] [ { } bitfield ] unit-test @@ -14,4 +14,4 @@ IN: math.bitfields.tests [ 3 ] [ foo ] unit-test [ 3 ] [ { a b } flags ] unit-test -[ t ] [ \ foo compiled>> ] unit-test +\ foo must-infer diff --git a/core/vectors/vectors-tests.factor b/core/vectors/vectors-tests.factor index 3b2c94b2e5..4f9bba3483 100755 --- a/core/vectors/vectors-tests.factor +++ b/core/vectors/vectors-tests.factor @@ -1,4 +1,4 @@ -USING: arrays kernel kernel.private math namespaces +USING: accessors arrays kernel kernel.private math namespaces sequences sequences.private strings tools.test vectors continuations random growable classes ; IN: vectors.tests @@ -70,14 +70,14 @@ IN: vectors.tests [ "funky" ] [ "funny-stack" get pop ] unit-test [ t ] [ - V{ 1 2 3 4 } dup underlying length - >r clone underlying length r> + V{ 1 2 3 4 } dup underlying>> length + >r clone underlying>> length r> = ] unit-test [ f ] [ V{ 1 2 3 4 } dup clone - [ underlying ] bi@ eq? + [ underlying>> ] bi@ eq? ] unit-test [ 0 ] [ diff --git a/extra/locals/locals.factor b/extra/locals/locals.factor index 46873d016c..8346c2c2c3 100755 --- a/extra/locals/locals.factor +++ b/extra/locals/locals.factor @@ -365,7 +365,7 @@ M: lambda-word definition "lambda" word-prop body>> ; M: lambda-word reset-word - [ f "lambda" set-word-prop ] [ call-next-method ] bi ; + [ call-next-method ] [ f "lambda" set-word-prop ] bi ; INTERSECTION: lambda-macro macro lambda-word ; diff --git a/extra/macros/macros.factor b/extra/macros/macros.factor index ccfc932406..17610f016a 100755 --- a/extra/macros/macros.factor +++ b/extra/macros/macros.factor @@ -24,7 +24,7 @@ M: macro definer drop \ MACRO: \ ; ; M: macro definition "macro" word-prop ; M: macro reset-word - [ f "macro" set-word-prop ] [ call-next-method ] bi ; + [ call-next-method ] [ f "macro" set-word-prop ] bi ; : macro-expand ( ... word -- quot ) "macro" word-prop call ; diff --git a/extra/memoize/memoize.factor b/extra/memoize/memoize.factor index aa6ebb532c..9a71832133 100755 --- a/extra/memoize/memoize.factor +++ b/extra/memoize/memoize.factor @@ -48,8 +48,8 @@ M: memoized definer drop \ MEMO: \ ; ; M: memoized definition "memo-quot" word-prop ; M: memoized reset-word - [ { "memoize" "memo-quot" } reset-props ] [ call-next-method ] + [ { "memoize" "memo-quot" } reset-props ] bi ; : memoize-quot ( quot effect -- memo-quot ) diff --git a/extra/present/present.factor b/extra/present/present.factor index 162a90122e..519e995fe5 100644 --- a/extra/present/present.factor +++ b/extra/present/present.factor @@ -1,5 +1,7 @@ -USING: math math.parser calendar calendar.format strings words -kernel effects ; +! Copyright (C) 2008 Slava Pestov. +! See http://factorcode.org/license.txt for BSD license. +USING: accessors math math.parser calendar calendar.format +strings words kernel effects ; IN: present GENERIC: present ( object -- string ) diff --git a/extra/tools/profiler/profiler-tests.factor b/extra/tools/profiler/profiler-tests.factor index 335733d109..d78e6fcbea 100755 --- a/extra/tools/profiler/profiler-tests.factor +++ b/extra/tools/profiler/profiler-tests.factor @@ -1,11 +1,11 @@ IN: tools.profiler.tests -USING: tools.profiler tools.test kernel memory math threads -alien tools.profiler.private sequences ; +USING: accessors tools.profiler tools.test kernel memory math +threads alien tools.profiler.private sequences ; [ t ] [ - \ length profile-counter + \ length counter>> 10 [ { } length drop ] times - \ length profile-counter = + \ length counter>> = ] unit-test [ ] [ [ 10 [ gc ] times ] profile ] unit-test @@ -31,7 +31,7 @@ alien tools.profiler.private sequences ; foobar ] profile -[ 1 ] [ \ foobar profile-counter ] unit-test +[ 1 ] [ \ foobar counter>> ] unit-test : fooblah { } [ ] each ; @@ -39,6 +39,6 @@ alien tools.profiler.private sequences ; [ foobaz ] profile -[ 1 ] [ \ foobaz profile-counter ] unit-test +[ 1 ] [ \ foobaz counter>> ] unit-test -[ 2 ] [ \ fooblah profile-counter ] unit-test +[ 2 ] [ \ fooblah counter>> ] unit-test diff --git a/extra/xml/utilities/utilities.factor b/extra/xml/utilities/utilities.factor index 91dd1903b4..209c0b55e9 100755 --- a/extra/xml/utilities/utilities.factor +++ b/extra/xml/utilities/utilities.factor @@ -1,6 +1,6 @@ ! Copyright (C) 2005, 2006 Daniel Ehrenberg ! See http://factorcode.org/license.txt for BSD license. -USING: kernel namespaces sequences words io assocs +USING: accessors kernel namespaces sequences words io assocs quotations strings parser lexer arrays xml.data xml.writer debugger splitting vectors sequences.deep combinators ; IN: xml.utilities