From 60f36cd9c89448c02c8b837f684ac4f71f55b264 Mon Sep 17 00:00:00 2001 From: Slava Pestov Date: Sat, 24 Jan 2009 20:17:11 -0600 Subject: [PATCH 1/2] Update user-space code for modify-code-heap primitive change --- basis/compiler/compiler.factor | 2 +- basis/stack-checker/known-words/known-words.factor | 2 +- core/compiler/units/units-tests.factor | 2 +- core/compiler/units/units.factor | 6 ++---- 4 files changed, 5 insertions(+), 7 deletions(-) diff --git a/basis/compiler/compiler.factor b/basis/compiler/compiler.factor index 84797981d1..f2f4e7aa9e 100644 --- a/basis/compiler/compiler.factor +++ b/basis/compiler/compiler.factor @@ -110,7 +110,7 @@ t compile-dependencies? set-global [ (compile) yield-hook get call ] slurp-deque ; : decompile ( word -- ) - f 2array 1array t modify-code-heap ; + f 2array 1array modify-code-heap ; : optimized-recompile-hook ( words -- alist ) [ diff --git a/basis/stack-checker/known-words/known-words.factor b/basis/stack-checker/known-words/known-words.factor index 3836fadeb7..7cdce301b5 100644 --- a/basis/stack-checker/known-words/known-words.factor +++ b/basis/stack-checker/known-words/known-words.factor @@ -643,7 +643,7 @@ M: object infer-call* \ dll-valid? { object } { object } define-primitive -\ modify-code-heap { array object } { } define-primitive +\ modify-code-heap { array } { } define-primitive \ unimplemented { } { } define-primitive diff --git a/core/compiler/units/units-tests.factor b/core/compiler/units/units-tests.factor index ba990b4247..5eafcef94e 100644 --- a/core/compiler/units/units-tests.factor +++ b/core/compiler/units/units-tests.factor @@ -11,7 +11,7 @@ accessors namespaces fry ; ! Non-optimizing compiler bugs [ 1 1 ] [ - "A" "B" [ [ 1 ] dip ] >>def dup f 2array 1array f modify-code-heap + "A" "B" [ [ 1 ] dip ] >>def dup f 2array 1array modify-code-heap 1 swap execute ] unit-test diff --git a/core/compiler/units/units.factor b/core/compiler/units/units.factor index 72496a5f76..999b783c48 100644 --- a/core/compiler/units/units.factor +++ b/core/compiler/units/units.factor @@ -66,9 +66,7 @@ GENERIC: definitions-changed ( assoc obj -- ) dup dup changed-vocabs update ; : compile ( words -- ) - recompile-hook get call - dup [ drop crossref? ] assoc-contains? - modify-code-heap ; + recompile-hook get call modify-code-heap ; SYMBOL: outdated-tuples SYMBOL: update-tuples-hook @@ -145,7 +143,7 @@ SYMBOL: remake-generics-hook call-recompile-hook call-update-tuples-hook unxref-forgotten-definitions - dup [ drop crossref? ] assoc-contains? modify-code-heap ; + modify-code-heap ; : with-nested-compilation-unit ( quot -- ) [ From 622015adabd60f47cd7bbd69f3a6ab14cf3602bb Mon Sep 17 00:00:00 2001 From: Slava Pestov Date: Sat, 24 Jan 2009 20:17:21 -0600 Subject: [PATCH 2/2] Fix regression in ui.gadgets:screen-rect --- basis/ui/gadgets/gadgets.factor | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/basis/ui/gadgets/gadgets.factor b/basis/ui/gadgets/gadgets.factor index e5a2b53096..2af0f6e6a2 100644 --- a/basis/ui/gadgets/gadgets.factor +++ b/basis/ui/gadgets/gadgets.factor @@ -315,7 +315,7 @@ SYMBOL: in-layout? : (screen-rect) ( gadget -- loc ext ) dup parent>> [ [ rect-extent ] dip (screen-rect) - [ [ nip ] [ v+ ] 2bi ] dip [ vmin ] [ v+ ] 2bi* + [ [ nip ] [ v+ ] 2bi ] dip [ v+ ] [ vmin ] 2bi* ] [ rect-extent ] if* ;