mirror of
https://github.com/dart-lang/sdk
synced 2024-09-16 02:47:36 +00:00
dart2js: Add comment in buildTypeArgumentRepresentations.
BUG= R=floitsch@google.com Review URL: https://codereview.chromium.org//1143243002
This commit is contained in:
parent
67537ffbd7
commit
cefd7f7d52
|
@ -3628,10 +3628,15 @@ class SsaBuilder extends NewResolvedVisitor {
|
|||
bool first = true;
|
||||
List<js.Expression> templates = <js.Expression>[];
|
||||
for (DartType argument in interface.typeArguments) {
|
||||
templates.add(rti.getTypeRepresentationWithPlaceholders(argument, (variable) {
|
||||
HInstruction runtimeType = addTypeVariableReference(variable);
|
||||
inputs.add(runtimeType);
|
||||
}, firstPlaceholderIndex : inputs.length));
|
||||
// As we construct the template in stages, we have to make sure that for
|
||||
// each part the generated sub-template's holes match the index of the
|
||||
// inputs that are later used to instantiate it. We do this by starting
|
||||
// the indexing with the number of inputs from previous sub-templates.
|
||||
templates.add(
|
||||
rti.getTypeRepresentationWithPlaceholders(argument, (variable) {
|
||||
HInstruction runtimeType = addTypeVariableReference(variable);
|
||||
inputs.add(runtimeType);
|
||||
}, firstPlaceholderIndex: inputs.length));
|
||||
}
|
||||
// TODO(sra): This is a fresh template each time. We can't let the
|
||||
// template manager build them.
|
||||
|
|
Loading…
Reference in a new issue