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

Unified Diff: tests/compiler/dart2js/mock_compiler.dart

Issue 14120008: Add special rules in the inferrer that some int operations return an int. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 8 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: tests/compiler/dart2js/mock_compiler.dart
===================================================================
--- tests/compiler/dart2js/mock_compiler.dart (revision 21800)
+++ tests/compiler/dart2js/mock_compiler.dart (working copy)
@@ -112,6 +112,9 @@
operator <(other) => true;
operator <=(other) => true;
operator ==(other) => true;
+
+ abs() => (this is JSInt) ? 42 : 42.0;
+ remainder(other) => (this is JSInt) ? 42 : 42.0;
}
class JSInt extends JSNumber implements int {
}

Powered by Google App Engine
This is Rietveld 408576698