Chromium Code Reviews| Index: sdk/lib/_internal/compiler/implementation/world.dart |
| =================================================================== |
| --- sdk/lib/_internal/compiler/implementation/world.dart (revision 19293) |
| +++ sdk/lib/_internal/compiler/implementation/world.dart (working copy) |
| @@ -51,7 +51,11 @@ |
| } |
| } |
| - compiler.resolverWorld.instantiatedClasses.forEach(addSubtypes); |
| + // Use the [:seenClasses:] set to include non-instantiated |
| + // classes: if the superclass of these classes require RTI, then |
| + // they also need RTI, so that a constructor passes the type |
| + // variables to the super constructor. |
| + compiler.enqueuer.resolution.seenClasses.forEach(addSubtypes); |
|
karlklose
2013/03/01 12:15:22
Could we create constraints to track this dependen
ngeoffray
2013/03/01 12:39:27
We could put a rti dependency. This would require
karlklose
2013/03/01 13:23:39
No, I don't have a case in mind.
|
| // Find the classes that need runtime type information. Such |
| // classes are: |
| @@ -64,6 +68,7 @@ |
| if (classesNeedingRti.contains(cls)) return; |
| classesNeedingRti.add(cls); |
| + // TODO(ngeoffray): This should use subclasses, not subtypes. |
|
karlklose
2013/03/01 12:15:22
I find this use of subtypes confusing, because the
ngeoffray
2013/03/01 12:39:27
Yes, this is mostly for historic reasons. I don't
|
| Set<ClassElement> classes = subtypes[cls]; |
| if (classes != null) { |
| classes.forEach((ClassElement sub) { |