Fix regression when forgetting classes
parent
238ec94e06
commit
bd479db2f8
|
@ -184,8 +184,10 @@ SINGLETON: optimizing-compiler
|
|||
M: optimizing-compiler update-call-sites ( class generic -- words )
|
||||
#! Words containing call sites with inferred type 'class'
|
||||
#! which inlined a method on 'generic'
|
||||
compiled-generic-usage swap
|
||||
'[ nip _ classes-intersect? ] assoc-filter keys ;
|
||||
compiled-generic-usage swap '[
|
||||
nip dup forgotten-class?
|
||||
[ drop f ] [ _ classes-intersect? ] if
|
||||
] assoc-filter keys ;
|
||||
|
||||
M: optimizing-compiler recompile ( words -- alist )
|
||||
[
|
||||
|
|
|
@ -40,13 +40,12 @@ M: object normalize-class ;
|
|||
|
||||
PRIVATE>
|
||||
|
||||
GENERIC: valid-class? ( obj -- ? )
|
||||
GENERIC: forgotten-class? ( obj -- ? )
|
||||
|
||||
M: class valid-class? drop t ;
|
||||
M: anonymous-union valid-class? members>> [ valid-class? ] all? ;
|
||||
M: anonymous-intersection valid-class? participants>> [ valid-class? ] all? ;
|
||||
M: anonymous-complement valid-class? class>> valid-class? ;
|
||||
M: word valid-class? drop f ;
|
||||
M: word forgotten-class? "forgotten" word-prop ;
|
||||
M: anonymous-union forgotten-class? members>> [ forgotten-class? ] any? ;
|
||||
M: anonymous-intersection forgotten-class? participants>> [ forgotten-class? ] any? ;
|
||||
M: anonymous-complement forgotten-class? class>> forgotten-class? ;
|
||||
|
||||
: class<= ( first second -- ? )
|
||||
class<=-cache get [ (class<=) ] 2cache ;
|
||||
|
|
Loading…
Reference in New Issue