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

Unified Diff: pkg/front_end/lib/src/fasta/analyzer/ast_builder.dart

Issue 2732213003: Fix for parsing generic function types with Fasta. (Closed)
Patch Set: 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/front_end/lib/src/fasta/analyzer/ast_builder.dart
diff --git a/pkg/front_end/lib/src/fasta/analyzer/ast_builder.dart b/pkg/front_end/lib/src/fasta/analyzer/ast_builder.dart
index 175ce815a37f718341692f394f63bfc4beff0463..36d09c63289966e435f19c643f4b2151ff5c36fa 100644
--- a/pkg/front_end/lib/src/fasta/analyzer/ast_builder.dart
+++ b/pkg/front_end/lib/src/fasta/analyzer/ast_builder.dart
@@ -593,6 +593,15 @@ class AstBuilder extends ScopeListener {
push(new _ParameterDefaultValue(equals, value));
}
+ void handleFunctionType(Token functionToken, Token semicolon) {
+ debugEvent("FunctionType");
+ FormalParameterList parameters = pop();
+ TypeParameterList typeParameters = pop();
+ TypeAnnotation returnType = pop();
+ push(ast.genericFunctionType(returnType, toAnalyzerToken(functionToken),
+ typeParameters, parameters));
+ }
+
void handleFormalParameterWithoutValue(Token token) {
debugEvent("FormalParameterWithoutValue");
push(NullValue.ParameterDefaultValue);
« no previous file with comments | « pkg/analyzer/test/generated/parser_fasta_test.dart ('k') | pkg/front_end/lib/src/fasta/parser/listener.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698