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

Unified Diff: pkg/compiler/lib/src/constants/constant_constructors.dart

Issue 2294753002: Handle parts as input in resolver. (Closed)
Patch Set: Created 4 years, 4 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/compiler/lib/src/constants/constant_constructors.dart
diff --git a/pkg/compiler/lib/src/constants/constant_constructors.dart b/pkg/compiler/lib/src/constants/constant_constructors.dart
index 996f8b13ccda1610f83e31fc6af7f7949235638d..7945601f13d6bf73096053f3dc8d083a824e1dc9 100644
--- a/pkg/compiler/lib/src/constants/constant_constructors.dart
+++ b/pkg/compiler/lib/src/constants/constant_constructors.dart
@@ -268,6 +268,18 @@ class ConstantConstructorComputer extends SemanticVisitor
}
@override
+ ConstantExpression visitEquals(Send node, Node left, Node right, _) {
Johnni Winther 2016/08/30 11:22:42 Missing implementation triggered by the test.
+ return new BinaryConstantExpression(
+ apply(left), BinaryOperator.EQ, apply(right));
+ }
+
+ @override
+ ConstantExpression visitNotEquals(Send node, Node left, Node right, _) {
+ return new BinaryConstantExpression(
+ apply(left), BinaryOperator.NOT_EQ, apply(right));
+ }
+
+ @override
ConstantExpression visitUnary(
Send node, UnaryOperator operator, Node expression, _) {
return new UnaryConstantExpression(operator, apply(expression));

Powered by Google App Engine
This is Rietveld 408576698