Chromium Code Reviews| Index: sdk/lib/_internal/compiler/implementation/ssa/builder.dart |
| diff --git a/sdk/lib/_internal/compiler/implementation/ssa/builder.dart b/sdk/lib/_internal/compiler/implementation/ssa/builder.dart |
| index 2ba5dddebc7ac0608480d7eabc9bd9ab74beb633..83080f18307ca558895ae52ad917adf9bfd36756 100644 |
| --- a/sdk/lib/_internal/compiler/implementation/ssa/builder.dart |
| +++ b/sdk/lib/_internal/compiler/implementation/ssa/builder.dart |
| @@ -3181,11 +3181,20 @@ class SsaBuilder extends ResolvedVisitor implements Visitor { |
| // The type variable is stored in a parameter of the method. |
| inputs.add(localsHandler.readLocal(type.element)); |
| } else if (member.isInstanceMember() || |
| - member.isGenerativeConstructor()) { |
| - // The type variable is stored in [this]. |
| + member.isGenerativeConstructor()) { |
| + // The type variable is stored on the object. |
|
kasperl
2013/02/12 12:14:10
Extend the comment with an example of the kind of
karlklose
2013/02/12 13:22:30
Done.
|
| int index = RuntimeTypeInformation.getTypeVariableIndex(type); |
| - pushInvokeHelper2(backend.getGetRuntimeTypeArgument(), |
| - localsHandler.readThis(), |
| + HInstruction thisObject = localsHandler.readThis(); |
| + String substituionNameString = |
|
kasperl
2013/02/12 12:14:10
substituion -> substitution
karlklose
2013/02/12 13:22:30
Done.
|
| + backend.namer.substitutionName(member.getEnclosingClass()); |
| + HInstruction substitutionName = graph.addConstantString( |
| + new LiteralDartString(substituionNameString), null, constantSystem); |
| + HInstruction substitution = createForeign('#[#]', HType.UNKNOWN, |
| + <HInstruction>[thisObject, substitutionName]); |
| + add(substitution); |
| + pushInvokeHelper3(backend.getGetRuntimeTypeArgument(), |
| + thisObject, |
| + substitution, |
| graph.addConstantInt(index, constantSystem), |
| HType.UNKNOWN); |
| inputs.add(pop()); |