From 00f586fc335bd9744dd9e78ae155ed422fb30ff8 Mon Sep 17 00:00:00 2001 From: Slava Pestov Date: Sat, 7 Mar 2009 00:49:57 -0600 Subject: [PATCH] Fix bootstrap: delegate cannot depend on locals since locals depends on delegate --- basis/delegate/delegate.factor | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/basis/delegate/delegate.factor b/basis/delegate/delegate.factor index 5e8d627434..0c16b7c336 100644 --- a/basis/delegate/delegate.factor +++ b/basis/delegate/delegate.factor @@ -4,7 +4,7 @@ USING: accessors arrays assocs classes.tuple definitions generic generic.standard hashtables kernel lexer math parser generic.parser sequences sets slots words words.symbol fry -locals combinators.short-circuit compiler.units ; +compiler.units ; IN: delegate > ] [ group>> ] bi \ protocol-consult word-prop delete-at ; -:: unconsult-method ( word consultation -- ) - consultation class>> word first method - dup { [ ] [ "consultation" word-prop consultation eq? ] } 1&& - [ forget ] [ drop ] if ; +: unconsult-method ( word consultation -- ) + [ class>> swap first method ] keep + over [ + over "consultation" word-prop eq? + [ forget ] [ drop ] if + ] [ 2drop ] if ; : unconsult-methods ( consultation -- ) [ unconsult-method ] each-generic ;