SmallSense__Manager.st
changeset 179 e444be9de40a
parent 174 3e08d765d86f
child 181 cd22fe147eb4
--- a/SmallSense__Manager.st	Thu Feb 27 10:15:47 2014 +0000
+++ b/SmallSense__Manager.st	Sat Mar 01 23:34:40 2014 +0000
@@ -168,7 +168,7 @@
 
 delayedUpdateInfoForClass: class
 
-    | superclass info instVarNames instVarTypes nprobed |
+    | superclass info instVarNames instVarTypes probe nprobed |
 
     superclass := class superclass.
     superclass notNil ifTrue:[self updateInfoForClass: superclass].
@@ -178,8 +178,7 @@
     instVarTypes := instVarNames collect: [:instvar | info infoForInstvar: instvar ]. 
     class methodsDo:[:mthd|updater add:mthd].
 
-    nprobed := 0.
-    class allInstancesDo: [:instance |
+    probe := [:instance |
         instVarTypes withIndexDo: [:instVarType :i | 
             instVarType union: ((Type withClass: (instance instVarAt: i) class) type trustfullness: 70). 
         ].
@@ -187,11 +186,17 @@
         nprobed > 100 ifTrue:[
             "/ Probe at most 100 instancess
             ^ self
-        ].
+        ].   
+    ].
+    nprobed := 0.
+    class allInstancesDo: probe.
+    "/ Maube an abstract class?
+    nprobed < 100 ifTrue:[ 
+        class allSubInstancesDo: probe
     ].
 
     "Created: / 27-11-2011 / 18:04:31 / Jan Vrany <jan.vrany@fit.cvut.cz>"
-    "Modified: / 22-10-2013 / 11:14:34 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+    "Modified: / 01-03-2014 / 00:44:03 / Jan Vrany <jan.vrany@fit.cvut.cz>"
 !
 
 delayedUpdateInfoForClassOrMethod: classOrMethod