| Index: runtime/vm/object.cc
|
| diff --git a/runtime/vm/object.cc b/runtime/vm/object.cc
|
| index d82136f54b05f7106c689f0ae51124369ace103a..edcdc3e765d4e3224281075b3779f772e75ee456 100644
|
| --- a/runtime/vm/object.cc
|
| +++ b/runtime/vm/object.cc
|
| @@ -16746,8 +16746,7 @@ bool Bigint::FitsIntoInt64() const {
|
| }
|
|
|
|
|
| -int64_t Bigint::AsInt64Value() const {
|
| - ASSERT(FitsIntoInt64());
|
| +int64_t Bigint::AsTruncatedInt64Value() const {
|
| const intptr_t used = Used();
|
| if (used == 0) return 0;
|
| const int64_t digit1 = (used > 1) ? DigitAt(1) : 0;
|
| @@ -16756,6 +16755,12 @@ int64_t Bigint::AsInt64Value() const {
|
| }
|
|
|
|
|
| +int64_t Bigint::AsInt64Value() const {
|
| + ASSERT(FitsIntoInt64());
|
| + return AsTruncatedInt64Value();
|
| +}
|
| +
|
| +
|
| bool Bigint::FitsIntoUint64() const {
|
| ASSERT(Bigint::kBitsPerDigit == 32);
|
| return !Neg() && (Used() <= 2);
|
|
|