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

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

Issue 2551023005: Prepare for decoupling analyzer ASTs from element model. (Closed)
Patch Set: Address review comments Created 4 years 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/analysis_server.dart
diff --git a/pkg/analysis_server/lib/src/analysis_server.dart b/pkg/analysis_server/lib/src/analysis_server.dart
index da64893198bca5d79093b7da48382b7c8232339e..bd1a352c8712814fb39002a406d6c553f813d22b 100644
--- a/pkg/analysis_server/lib/src/analysis_server.dart
+++ b/pkg/analysis_server/lib/src/analysis_server.dart
@@ -27,6 +27,7 @@ import 'package:analysis_server/src/services/search/search_engine_internal.dart'
import 'package:analysis_server/src/services/search/search_engine_internal2.dart';
import 'package:analysis_server/src/single_context_manager.dart';
import 'package:analyzer/dart/ast/ast.dart';
+import 'package:analyzer/dart/ast/standard_resolution_map.dart';
import 'package:analyzer/dart/element/element.dart';
import 'package:analyzer/exception/exception.dart';
import 'package:analyzer/file_system/file_system.dart';
@@ -1269,7 +1270,8 @@ class AnalysisServer {
sendAnalysisNotificationHighlights(this, file, dartUnit);
break;
case AnalysisService.OUTLINE:
- AnalysisContext context = dartUnit.element.context;
+ AnalysisContext context =
+ resolutionMap.elementForCompilationUnit(dartUnit).context;
LineInfo lineInfo = context.getLineInfo(source);
SourceKind kind = context.getKindOf(source);
sendAnalysisNotificationOutline(

Powered by Google App Engine
This is Rietveld 408576698