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

Unified Diff: pkg/analysis_server/lib/src/services/completion/arglist_computer.dart

Issue 967643002: throw exception to stop visiting (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 5 years, 10 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
« no previous file with comments | « no previous file | pkg/analysis_server/lib/src/services/completion/invocation_computer.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analysis_server/lib/src/services/completion/arglist_computer.dart
diff --git a/pkg/analysis_server/lib/src/services/completion/arglist_computer.dart b/pkg/analysis_server/lib/src/services/completion/arglist_computer.dart
index 812173875eb9f46348cbc07a553336a8a3555175..7d858468107fb7c7619badf6f3ae61a95e3956a6 100644
--- a/pkg/analysis_server/lib/src/services/completion/arglist_computer.dart
+++ b/pkg/analysis_server/lib/src/services/completion/arglist_computer.dart
@@ -61,8 +61,10 @@ class _ArgListAstVisitor extends
* indicating that suggestions were added
* and no further action is necessary
*/
- if (node.accept(
- new _LocalDeclarationFinder(request, request.offset, name))) {
+ if (new _LocalDeclarationFinder(
+ request,
+ request.offset,
+ name).visit(node)) {
return null;
}
} else {
@@ -126,8 +128,8 @@ class _LocalDeclarationFinder extends LocalDeclarationVisitor {
void declaredFunction(FunctionDeclaration declaration) {
SimpleIdentifier selector = declaration.name;
if (selector != null && name == selector.name) {
- finished = true;
_addArgListSuggestion(declaration.functionExpression.parameters);
+ finished();
}
}
@@ -147,8 +149,8 @@ class _LocalDeclarationFinder extends LocalDeclarationVisitor {
void declaredMethod(MethodDeclaration declaration) {
SimpleIdentifier selector = declaration.name;
if (selector != null && name == selector.name) {
- finished = true;
_addArgListSuggestion(declaration.parameters);
+ finished();
}
}
« no previous file with comments | « no previous file | pkg/analysis_server/lib/src/services/completion/invocation_computer.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698