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

Side by Side Diff: sdk/lib/core/int.dart

Issue 23522037: one-liners for the remaining top-50 dart:core classes (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: incorporate memfeedback Created 7 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 part of dart.core; 5 part of dart.core;
6 6
7 /** 7 /**
8 * Representation of Dart integers containing integer specific 8 * An arbitrarily large integer.
9 * operations and specialization of operations inherited from [num].
10 * 9 *
11 * Integers can be arbitrarily large in Dart. 10 * **Note:** When compiling to JavaScript, integers are
12 *
13 * *Note however, that when compiling to JavaScript, integers are
14 * implemented as JavaScript numbers. When compiling to JavaScript, 11 * implemented as JavaScript numbers. When compiling to JavaScript,
15 * integers are therefore restricted to 53 significant bits because 12 * integers are therefore restricted to 53 significant bits because
16 * all JavaScript numbers are double-precision floating point 13 * all JavaScript numbers are double-precision floating point
17 * values. The behavior of the operators and methods in the [int] 14 * values. The behavior of the operators and methods in the [int]
18 * class therefore sometimes differs between the Dart VM and Dart code 15 * class therefore sometimes differs between the Dart VM and Dart code
19 * compiled to JavaScript.* 16 * compiled to JavaScript.
20 * 17 *
21 * It is a compile-time error for a class to attempt to extend or implement int. 18 * It is a compile-time error for a class to attempt to extend or implement int.
22 */ 19 */
23 abstract class int extends num { 20 abstract class int extends num {
24 /** 21 /**
25 * Bit-wise and operator. 22 * Bit-wise and operator.
26 * 23 *
27 * Treating both `this` and [other] as sufficiently large two's component 24 * Treating both `this` and [other] as sufficiently large two's component
28 * integers, the result is a number with only the bits set that are set in 25 * integers, the result is a number with only the bits set that are set in
29 * both `this` and [other] 26 * both `this` and [other]
(...skipping 219 matching lines...) Expand 10 before | Expand all | Expand 10 after
249 * value is used instead. If no [onError] is provided, a [FormatException] 246 * value is used instead. If no [onError] is provided, a [FormatException]
250 * is thrown. 247 * is thrown.
251 * 248 *
252 * The [onError] function is only invoked if [source] is a [String]. It is 249 * The [onError] function is only invoked if [source] is a [String]. It is
253 * not invoked if the [source] is, for example, `null`. 250 * not invoked if the [source] is, for example, `null`.
254 */ 251 */
255 external static int parse(String source, 252 external static int parse(String source,
256 { int radix, 253 { int radix,
257 int onError(String source) }); 254 int onError(String source) });
258 } 255 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698