| 109 | return value->as_i64(); |
| 110 | } |
| 111 | |
| 112 | inline int optional_i32(const Value & object, const std::string & key, int default_value) { |
| 113 | return static_cast<int>(optional_i64(object, key, default_value)); |
| 114 | } |
| 115 | |
| 116 | inline float optional_f32(const Value & object, const std::string & key, float default_value) { |
| 117 | const auto * value = object.find(key); |
no test coverage detected