There are warnings on unused variables on both clang and GCC when exceptions are disabled, just pulled from latest commit ( 43e07bb ) on develop branch.
template<class Exception>
bool parse_error(std::size_t /*unused*/, const std::string& /*unused*/,
const Exception& ex)
{
errored = true;
if (allow_exceptions)
{
JSON_THROW(ex);
}
return false;
}
GCC 10.1.0
third-party/json/single_include/nlohmann/json.hpp|5441 col 39| warning: unused parameter ‘ex’ [-Wunused-parameter]
|| 5441 | const Exception& ex)
|| | ~~~~~~~~~~~~~~~~~^~
Clang 10.0
third-party/json/single_include/nlohmann/json.hpp:5441:39: warning: unused parameter 'ex' [-Wunused-parameter]
const Exception& ex)
Pretty sure this is because JSON_THROW is an empty macro so ex does nothing.
There are warnings on unused variables on both clang and GCC when exceptions are disabled, just pulled from latest commit ( 43e07bb ) on develop branch.
GCC 10.1.0
Clang 10.0
Pretty sure this is because JSON_THROW is an empty macro so ex does nothing.