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

Unified Diff: sdk/lib/_internal/lib/js_number.dart

Issue 28973002: Add isFinite getter to num. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Change comments to not use "whether". Created 7 years, 2 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 | « runtime/lib/integers.dart ('k') | sdk/lib/core/num.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sdk/lib/_internal/lib/js_number.dart
diff --git a/sdk/lib/_internal/lib/js_number.dart b/sdk/lib/_internal/lib/js_number.dart
index b5591fb6e41fe44e5a74389dcc906c03729033d6..40a3c7f8cc34451145dc96e58952569a78c86dad 100644
--- a/sdk/lib/_internal/lib/js_number.dart
+++ b/sdk/lib/_internal/lib/js_number.dart
@@ -49,6 +49,8 @@ class JSNumber extends Interceptor implements num {
|| JS('bool', r'# == -Infinity', this);
}
+ bool get isFinite => JS('bool', r'isFinite(#)', this);
+
num remainder(num b) {
checkNull(b); // TODO(ngeoffray): This is not specified but co19 tests it.
if (b is! num) throw new ArgumentError(b);
« no previous file with comments | « runtime/lib/integers.dart ('k') | sdk/lib/core/num.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698