Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(388)

Unified Diff: pkg/compiler/lib/src/parser/node_listener.dart

Issue 2750503012: Re-land "Add support for metadata on type variables to Fasta parser." (with fixes). (Closed)
Patch Set: Fixes Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: pkg/compiler/lib/src/parser/node_listener.dart
diff --git a/pkg/compiler/lib/src/parser/node_listener.dart b/pkg/compiler/lib/src/parser/node_listener.dart
index 81a29c31764f884f35909c2f6baf63a76feb9faf..e004b59755c1bc9148ee3b353fc558eb31681353 100644
--- a/pkg/compiler/lib/src/parser/node_listener.dart
+++ b/pkg/compiler/lib/src/parser/node_listener.dart
@@ -1009,6 +1009,18 @@ class NodeListener extends ElementListener {
}
@override
+ void endTypeVariable(Token token, Token extendsOrSuper) {
+ inTypeVariable = false;
+ NominalTypeAnnotation bound = popNode();
+ Identifier name = popNode();
+ // TODO(paulberry): type variable metadata should not be ignored. See
+ // dartbug.com/5841.
+ popNode(); // Metadata
+ pushNode(new TypeVariable(name, extendsOrSuper, bound));
+ rejectBuiltInIdentifier(name);
+ }
+
+ @override
void log(message) {
reporter.log(message);
}
« no previous file with comments | « pkg/compiler/lib/src/parser/member_listener.dart ('k') | pkg/front_end/lib/src/fasta/analyzer/ast_builder.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698