| OLD | NEW |
| 1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 the V8 project authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "src/v8.h" | |
| 6 | |
| 7 #include "src/bignum.h" | 5 #include "src/bignum.h" |
| 8 #include "src/utils.h" | 6 #include "src/utils.h" |
| 9 | 7 |
| 10 namespace v8 { | 8 namespace v8 { |
| 11 namespace internal { | 9 namespace internal { |
| 12 | 10 |
| 13 Bignum::Bignum() | 11 Bignum::Bignum() |
| 14 : bigits_(bigits_buffer_, kBigitCapacity), used_digits_(0), exponent_(0) { | 12 : bigits_(bigits_buffer_, kBigitCapacity), used_digits_(0), exponent_(0) { |
| 15 for (int i = 0; i < kBigitCapacity; ++i) { | 13 for (int i = 0; i < kBigitCapacity; ++i) { |
| 16 bigits_[i] = 0; | 14 bigits_[i] = 0; |
| (...skipping 728 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 745 bigits_[i] = difference & kBigitMask; | 743 bigits_[i] = difference & kBigitMask; |
| 746 borrow = difference >> (kChunkSize - 1); | 744 borrow = difference >> (kChunkSize - 1); |
| 747 } | 745 } |
| 748 Clamp(); | 746 Clamp(); |
| 749 DCHECK(Bignum::Equal(a, *this)); | 747 DCHECK(Bignum::Equal(a, *this)); |
| 750 } | 748 } |
| 751 | 749 |
| 752 | 750 |
| 753 } // namespace internal | 751 } // namespace internal |
| 754 } // namespace v8 | 752 } // namespace v8 |
| OLD | NEW |