| 3744 | } |
| 3745 | |
| 3746 | bool Value::isUInt() const { |
| 3747 | switch (type_) { |
| 3748 | case intValue: |
| 3749 | #if defined(JSON_HAS_INT64) |
| 3750 | return value_.int_ >= 0 && LargestUInt(value_.int_) <= LargestUInt(maxUInt); |
| 3751 | #else |
| 3752 | return value_.int_ >= 0; |
| 3753 | #endif |
| 3754 | case uintValue: |
| 3755 | #if defined(JSON_HAS_INT64) |
| 3756 | return value_.uint_ <= maxUInt; |
| 3757 | #else |
| 3758 | return true; |
| 3759 | #endif |
| 3760 | case realValue: |
| 3761 | return value_.real_ >= 0 && value_.real_ <= maxUInt && |
| 3762 | IsIntegral(value_.real_); |
| 3763 | default: |
| 3764 | break; |
| 3765 | } |
| 3766 | return false; |
| 3767 | } |
| 3768 | |
| 3769 | bool Value::isInt64() const { |
| 3770 | #if defined(JSON_HAS_INT64) |
nothing calls this directly
no test coverage detected