MCPcopy Create free account
hub / github.com/Kitware/CMake / isInt

Method isInt

Utilities/cmjsoncpp/src/lib_json/json_value.cpp:1261–1278  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1259bool Value::isBool() const { return type() == booleanValue; }
1260
1261bool Value::isInt() const {
1262 switch (type()) {
1263 case intValue:
1264#if defined(JSON_HAS_INT64)
1265 return value_.int_ >= minInt && value_.int_ <= maxInt;
1266#else
1267 return true;
1268#endif
1269 case uintValue:
1270 return value_.uint_ <= UInt(maxInt);
1271 case realValue:
1272 return value_.real_ >= minInt && value_.real_ <= maxInt &&
1273 IsIntegral(value_.real_);
1274 default:
1275 break;
1276 }
1277 return false;
1278}
1279
1280bool Value::isUInt() const {
1281 switch (type()) {

Callers 3

VersionHelperFunction · 0.80
IntFunction · 0.80
ParseRootFunction · 0.80

Calls 3

UIntFunction · 0.85
IsIntegralFunction · 0.85
typeClass · 0.50

Tested by

no test coverage detected