mirror of
https://github.com/vcmi/vcmi.git
synced 2025-03-21 21:17:49 +02:00
Try to fix compilation error:
/home/runner/work/vcmi/vcmi/test/../Global.h:700:36: error: no matching function for call to 'max' const Floating relativeEpsilon = std::max(std::abs(left), std::abs(right)) * epsilon; ^~~~~~~~ /home/runner/work/vcmi/vcmi/test/JsonComparer.cpp:48:16: note: in instantiation of function template specialization 'vstd::isAlmostEqual<double, int>' requested here return vstd::isAlmostEqual(value.Float(), 0); ^
This commit is contained in:
parent
fc1e9f70f9
commit
06a56a0ec3
@ -45,7 +45,7 @@ bool JsonComparer::isEmpty(const JsonNode & value)
|
||||
case JsonNode::JsonType::DATA_BOOL:
|
||||
return !value.Bool();
|
||||
case JsonNode::JsonType::DATA_FLOAT:
|
||||
return vstd::isAlmostEqual(value.Float(), 0);
|
||||
return vstd::isAlmostEqual(value.Float(), 0.0);
|
||||
case JsonNode::JsonType::DATA_INTEGER:
|
||||
return value.Integer() == 0;
|
||||
case JsonNode::JsonType::DATA_STRING:
|
||||
|
Loading…
x
Reference in New Issue
Block a user