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

Unified Diff: pkg/compiler/lib/src/resolution/tree_elements.dart

Issue 1520293002: Add token invariant to DiagnosticReporter (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Rebase + status update Created 5 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
« no previous file with comments | « pkg/compiler/lib/src/resolution/resolution.dart ('k') | tests/co19/co19-dart2js.status » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/compiler/lib/src/resolution/tree_elements.dart
diff --git a/pkg/compiler/lib/src/resolution/tree_elements.dart b/pkg/compiler/lib/src/resolution/tree_elements.dart
index e04b537255ba7fbbfc5cd0c9c6448a86ee949fcf..a60bb79b469c79eb5a38363f8ff6173252075c6b 100644
--- a/pkg/compiler/lib/src/resolution/tree_elements.dart
+++ b/pkg/compiler/lib/src/resolution/tree_elements.dart
@@ -7,6 +7,7 @@ library dart2js.resolution.tree_elements;
import '../common.dart';
import '../constants/expressions.dart';
import '../dart_types.dart';
+import '../diagnostics/source_span.dart';
import '../elements/elements.dart';
import '../types/types.dart' show
TypeMask;
@@ -22,7 +23,7 @@ import 'send_structure.dart';
abstract class TreeElements {
AnalyzableElement get analyzedElement;
- Iterable<Node> get superUses;
+ Iterable<SourceSpan> get superUses;
void forEachConstantNode(f(Node n, ConstantExpression c));
@@ -111,7 +112,7 @@ class TreeElementMapping extends TreeElements {
Map<Spannable, TypeMask> _typeMasks;
Map<Node, DartType> _types;
Map<Node, DartType> typesCache = <Node, DartType>{};
- Setlet<Node> _superUses;
+ Setlet<SourceSpan> _superUses;
Map<Node, ConstantExpression> _constants;
Map<VariableElement, List<Node>> _potentiallyMutated;
Map<Node, Map<VariableElement, List<Node>>> _potentiallyMutatedIn;
@@ -191,15 +192,15 @@ class TreeElementMapping extends TreeElements {
DartType getType(Node node) => _types != null ? _types[node] : null;
- Iterable<Node> get superUses {
- return _superUses != null ? _superUses : const <Node>[];
+ Iterable<SourceSpan> get superUses {
+ return _superUses != null ? _superUses : const <SourceSpan>[];
}
- void addSuperUse(Node node) {
+ void addSuperUse(SourceSpan span) {
if (_superUses == null) {
- _superUses = new Setlet<Node>();
+ _superUses = new Setlet<SourceSpan>();
}
- _superUses.add(node);
+ _superUses.add(span);
}
Selector _getSelector(Spannable node) {
« no previous file with comments | « pkg/compiler/lib/src/resolution/resolution.dart ('k') | tests/co19/co19-dart2js.status » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698