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

Unified Diff: lib/compiler/implementation/js_backend/backend.dart

Issue 10916172: num implements Comparable and Hashable. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 years, 3 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/elements/elements.dart ('k') | lib/compiler/implementation/lib/js_helper.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/compiler/implementation/js_backend/backend.dart
===================================================================
--- lib/compiler/implementation/js_backend/backend.dart (revision 12025)
+++ lib/compiler/implementation/js_backend/backend.dart (working copy)
@@ -702,8 +702,14 @@
return const SourceString('functionTypeCheck');
} else if (element == compiler.intClass) {
return const SourceString('intTypeCheck');
- } else if (Elements.isStringSupertype(element, compiler)) {
+ } else if (Elements.isNumberOrStringSupertype(element, compiler)) {
if (nativeCheck) {
kasperl 2012/09/07 13:03:46 Maybe use return ? : in these cases in this file?
ngeoffray 2012/09/07 14:06:36 Done.
+ return const SourceString('numberOrStringSuperNativeTypeCheck');
+ } else {
+ return const SourceString('numberOrStringSuperTypeCheck');
+ }
+ } else if (Elements.isStringOnlySupertype(element, compiler)) {
+ if (nativeCheck) {
return const SourceString('stringSuperNativeTypeCheck');
} else {
return const SourceString('stringSuperTypeCheck');
« no previous file with comments | « lib/compiler/implementation/elements/elements.dart ('k') | lib/compiler/implementation/lib/js_helper.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698