fix #allClasses, to skip aliases but not javaClasses
authorClaus Gittinger <cg@exept.de>
Wed, 01 Mar 2000 21:42:45 +0100
changeset 5285 c3920e83d753
parent 5284 37c436edfa71
child 5286 4ab4d9d0c2b5
fix #allClasses, to skip aliases but not javaClasses
Smalltalk.st
--- a/Smalltalk.st	Tue Feb 29 19:09:25 2000 +0100
+++ b/Smalltalk.st	Wed Mar 01 21:42:45 2000 +0100
@@ -1557,9 +1557,21 @@
         self keysAndValuesDo:[:sym :anObject |
             anObject notNil ifTrue:[
                 anObject isBehavior ifTrue:[
-"/                    anObject name == sym ifTrue:[
+                    "/ sigh - would like to skip over aliases
+                    "/ but this cannot be done simply by comparing
+                    "/ the classes name against the store-key
+                    "/ i.e. cannot do:
+                    "/      anObject name == sym ifTrue:[
+                    "/          classes add:anObject
+                    "/      ]
+                    "/ because that would lead to ignore of all java
+                    "/ classes, which are stored under a different
+                    "/ key.
+
+                    (anObject name == sym
+                    or:[anObject isJavaClass]) ifTrue:[
                         classes add:anObject
-"/                    ]
+                    ].
                 ]
             ]
         ]
@@ -5535,5 +5547,5 @@
 !Smalltalk class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libbasic/Smalltalk.st,v 1.436 2000-02-29 14:59:16 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libbasic/Smalltalk.st,v 1.437 2000-03-01 20:42:45 cg Exp $'
 ! !