| 3789 | bool Value::isBool() const { return type_ == booleanValue; } |
| 3790 | |
| 3791 | bool Value::isInt() const { |
| 3792 | switch (type_) { |
| 3793 | case intValue: |
| 3794 | #if defined(JSON_HAS_INT64) |
| 3795 | return value_.int_ >= minInt && value_.int_ <= maxInt; |
| 3796 | #else |
| 3797 | return true; |
| 3798 | #endif |
| 3799 | case uintValue: |
| 3800 | return value_.uint_ <= UInt(maxInt); |
| 3801 | case realValue: |
| 3802 | return value_.real_ >= minInt && value_.real_ <= maxInt && |
| 3803 | IsIntegral(value_.real_); |
| 3804 | default: |
| 3805 | break; |
| 3806 | } |
| 3807 | return false; |
| 3808 | } |
| 3809 | |
| 3810 | bool Value::isUInt() const { |
| 3811 | switch (type_) { |
no test coverage detected