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

Side by Side Diff: pkg/fixnum/lib/src/int64.dart

Issue 1829113003: Fix --strong warnings in pkg/fixnum (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Created 4 years, 9 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
« no previous file with comments | « no previous file | pkg/fixnum/lib/src/intx.dart » ('j') | pkg/fixnum/lib/src/intx.dart » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 fixnum; 5 part of fixnum;
6 6
7 /** 7 /**
8 * An immutable 64-bit signed integer, in the range [-2^63, 2^63 - 1]. 8 * An immutable 64-bit signed integer, in the range [-2^63, 2^63 - 1].
9 * Arithmetic operations may overflow in order to maintain this range. 9 * Arithmetic operations may overflow in order to maintain this range.
10 */ 10 */
(...skipping 12 matching lines...) Expand all
23 23
24 final int _l, _m, _h; 24 final int _l, _m, _h;
25 25
26 // Note: several functions require _BITS == 22 -- do not change this value. 26 // Note: several functions require _BITS == 22 -- do not change this value.
27 static const int _BITS = 22; 27 static const int _BITS = 22;
28 static const int _BITS01 = 44; // 2 * _BITS 28 static const int _BITS01 = 44; // 2 * _BITS
29 static const int _BITS2 = 20; // 64 - _BITS01 29 static const int _BITS2 = 20; // 64 - _BITS01
30 static const int _MASK = 4194303; // (1 << _BITS) - 1 30 static const int _MASK = 4194303; // (1 << _BITS) - 1
31 static const int _MASK2 = 1048575; // (1 << _BITS2) - 1 31 static const int _MASK2 = 1048575; // (1 << _BITS2) - 1
32 static const int _SIGN_BIT = 19; // _BITS2 - 1 32 static const int _SIGN_BIT = 19; // _BITS2 - 1
33 static const int _SIGN_BIT_MASK = 524288; // 1 << _SIGN_BIT 33 static const int _SIGN_BIT_MASK = 1 << _SIGN_BIT;
34 34
35 /** 35 /**
36 * The maximum positive value attainable by an [Int64], namely 36 * The maximum positive value attainable by an [Int64], namely
37 * 9,223,372,036,854,775,807. 37 * 9,223,372,036,854,775,807.
38 */ 38 */
39 static const Int64 MAX_VALUE = const Int64._bits(_MASK, _MASK, _MASK2 >> 1); 39 static const Int64 MAX_VALUE = const Int64._bits(_MASK, _MASK, _MASK2 >> 1);
40 40
41 /** 41 /**
42 * The minimum positive value attainable by an [Int64], namely 42 * The minimum positive value attainable by an [Int64], namely
43 * -9,223,372,036,854,775,808. 43 * -9,223,372,036,854,775,808.
(...skipping 949 matching lines...) Expand 10 before | Expand all | Expand 10 after
993 if (r0 == 0 && r1 == 0 && r2 == 0) { 993 if (r0 == 0 && r1 == 0 && r2 == 0) {
994 return ZERO; 994 return ZERO;
995 } else { 995 } else {
996 return _sub(b0, b1, b2, r0, r1, r2); 996 return _sub(b0, b1, b2, r0, r1, r2);
997 } 997 }
998 } else { 998 } else {
999 return _negate(r0, r1, r2); 999 return _negate(r0, r1, r2);
1000 } 1000 }
1001 } 1001 }
1002 } 1002 }
OLDNEW
« no previous file with comments | « no previous file | pkg/fixnum/lib/src/intx.dart » ('j') | pkg/fixnum/lib/src/intx.dart » ('J')

Powered by Google App Engine
This is Rietveld 408576698