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

Unified Diff: tests/language/positive_bit_operations_test.dart

Issue 10378047: Fix bad precedence for >>> operator. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 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 | « lib/compiler/implementation/ssa/codegen.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/language/positive_bit_operations_test.dart
diff --git a/tests/language/positive_bit_operations_test.dart b/tests/language/positive_bit_operations_test.dart
index 730d5cf861c4dc8aae742637527693e44889600d..86af1a1586a4d76f9fe94a43619bd0e57f6e956d 100644
--- a/tests/language/positive_bit_operations_test.dart
+++ b/tests/language/positive_bit_operations_test.dart
@@ -108,8 +108,17 @@ speculative() {
}
}
+// Due to bad precedence rules this example was broken in Dart2Js.
+precedence() {
+ Expect.equals(0x80000000, -1 & 0x80000000);
+ Expect.equals(0x80000000, id(-1) & 0x80000000);
+ Expect.equals(0x80000000, ~(~(0x80000000)));
+ Expect.equals(0x80000000, ~(~(id(0x80000000))));
+}
+
main() {
constants();
interceptors();
speculative();
+ precedence();
}
« no previous file with comments | « lib/compiler/implementation/ssa/codegen.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698