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

Unified Diff: pkg/front_end/lib/src/fasta/kernel/frontend_accessors.dart

Issue 2909013002: Clean up shared names. (Closed)
Patch Set: Created 3 years, 7 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/front_end/lib/src/fasta/names.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/front_end/lib/src/fasta/kernel/frontend_accessors.dart
diff --git a/pkg/front_end/lib/src/fasta/kernel/frontend_accessors.dart b/pkg/front_end/lib/src/fasta/kernel/frontend_accessors.dart
index 92582582324802ea6a91e0021aadb24c724dd63a..336169c7bd4e5ff37ff22b0703bbad5ef5ff702f 100644
--- a/pkg/front_end/lib/src/fasta/kernel/frontend_accessors.dart
+++ b/pkg/front_end/lib/src/fasta/kernel/frontend_accessors.dart
@@ -23,9 +23,7 @@ import 'package:front_end/src/fasta/kernel/fasta_accessors.dart'
import 'package:kernel/ast.dart' hide MethodInvocation;
-final Name indexGetName = new Name("[]");
-
-final Name indexSetName = new Name("[]=");
+import '../names.dart' show equalsName, indexGetName, indexSetName;
/// An [Accessor] represents a subexpression for which we can't yet build a
/// kernel [Expression] because we don't yet know the context in which it is
@@ -523,11 +521,8 @@ Expression makeBinary(
..fileOffset = offset;
}
-final Name _equalOperator = new Name('==');
-
Expression buildIsNull(Expression value, {int offset: TreeNode.noOffset}) {
- return makeBinary(value, _equalOperator, null, new NullLiteral(),
- offset: offset);
+ return makeBinary(value, equalsName, null, new NullLiteral(), offset: offset);
}
VariableDeclaration makeOrReuseVariable(Expression value) {
« no previous file with comments | « no previous file | pkg/front_end/lib/src/fasta/names.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698