| 464 | } |
| 465 | |
| 466 | SINT64 Int128::toInt64(int scale) const |
| 467 | { |
| 468 | Int128 tmp(*this); |
| 469 | tmp.setScale(scale); |
| 470 | if (tmp.v < i64min.v || tmp.v > i64max.v) |
| 471 | overflow(); |
| 472 | |
| 473 | unsigned dwords[4]; |
| 474 | tmp.getTable32(dwords); |
| 475 | SINT64 rc = int(dwords[1]); |
| 476 | rc <<= 32; |
| 477 | rc += dwords[0]; |
| 478 | |
| 479 | return rc; |
| 480 | } |
| 481 | |
| 482 | double Int128::toDouble() const |
| 483 | { |
no test coverage detected