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

Unified Diff: pkg/analysis_server/lib/src/computer/computer_outline.dart

Issue 2613383003: Add support for generic function type syntax, part 1 (Closed)
Patch Set: Created 3 years, 11 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/analysis_server/lib/src/computer/computer_outline.dart
diff --git a/pkg/analysis_server/lib/src/computer/computer_outline.dart b/pkg/analysis_server/lib/src/computer/computer_outline.dart
index a89ff0230fe1e4c188c47a6d39ee3defed6e7d92..f72cbe9843e957eb3ab0653fb4593c1f0333d9ef 100644
--- a/pkg/analysis_server/lib/src/computer/computer_outline.dart
+++ b/pkg/analysis_server/lib/src/computer/computer_outline.dart
@@ -40,7 +40,7 @@ class DartUnitOutlineComputer {
FieldDeclaration fieldDeclaration = classMember;
VariableDeclarationList fields = fieldDeclaration.fields;
if (fields != null) {
- TypeName fieldType = fields.type;
+ TypeAnnotation fieldType = fields.type;
String fieldTypeName = _safeToSource(fieldType);
for (VariableDeclaration field in fields.variables) {
classContents.add(_newVariableOutline(fieldTypeName,
@@ -67,7 +67,7 @@ class DartUnitOutlineComputer {
TopLevelVariableDeclaration fieldDeclaration = unitMember;
VariableDeclarationList fields = fieldDeclaration.variables;
if (fields != null) {
- TypeName fieldType = fields.type;
+ TypeAnnotation fieldType = fields.type;
String fieldTypeName = _safeToSource(fieldType);
for (VariableDeclaration field in fields.variables) {
unitContents.add(_newVariableOutline(
@@ -251,7 +251,7 @@ class DartUnitOutlineComputer {
}
Outline _newFunctionOutline(FunctionDeclaration function, bool isStatic) {
- TypeName returnType = function.returnType;
+ TypeAnnotation returnType = function.returnType;
SimpleIdentifier nameNode = function.name;
String name = nameNode.name;
FunctionExpression functionExpression = function.functionExpression;
@@ -285,7 +285,7 @@ class DartUnitOutlineComputer {
}
Outline _newFunctionTypeAliasOutline(FunctionTypeAlias node) {
- TypeName returnType = node.returnType;
+ TypeAnnotation returnType = node.returnType;
SimpleIdentifier nameNode = node.name;
String name = nameNode.name;
_SourceRegion sourceRegion = _getSourceRegion(node);
@@ -306,7 +306,7 @@ class DartUnitOutlineComputer {
}
Outline _newMethodOutline(MethodDeclaration method) {
- TypeName returnType = method.returnType;
+ TypeAnnotation returnType = method.returnType;
SimpleIdentifier nameNode = method.name;
String name = nameNode.name;
FormalParameterList parameters = method.parameters;

Powered by Google App Engine
This is Rietveld 408576698