Index: pkg/compiler/lib/src/elements/modelx.dart |
diff --git a/pkg/compiler/lib/src/elements/modelx.dart b/pkg/compiler/lib/src/elements/modelx.dart |
index c2d2e75ae8cc45f0d91cfc5d4ab4e79400a14816..4c850bb9c7fbffb0f9a71895f62d42dbc8f97005 100644 |
--- a/pkg/compiler/lib/src/elements/modelx.dart |
+++ b/pkg/compiler/lib/src/elements/modelx.dart |
@@ -1343,7 +1343,7 @@ class TypedefElementX extends ElementX |
TypedefType computeType(Resolution resolution) { |
if (thisTypeCache != null) return thisTypeCache; |
Typedef node = parseNode(resolution.parsingContext); |
- setThisAndRawTypes(createTypeVariables(node.typeParameters)); |
+ setThisAndRawTypes(createTypeVariables(node.templateParameters)); |
ensureResolved(resolution); |
return thisTypeCache; |
} |
@@ -1740,6 +1740,15 @@ class FormalElementX extends ElementX |
: this.identifier = identifier, |
super(identifier.source, elementKind, enclosingElement); |
+ FormalElementX.unnamed(ElementKind elementKind, |
+ FunctionTypedElement enclosingElement, |
+ this.definitions) |
+ : this.identifier = null, |
+ super("<unnamed>", elementKind, enclosingElement); |
+ |
+ /// Whether this is an unnamed parameter in a Function type. |
+ bool get isUnnamed => identifier == null; |
+ |
FunctionTypedElement get functionDeclaration => enclosingElement; |
Modifiers get modifiers => definitions.modifiers; |