You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I don't want to catch std::invalid_argument. I know I can provide my own error handler, but it looks identical to the default one except that it throws a subclass of std::invalid_argument.
So I wonder if the lib itself could not just do that by default?
I haven't spent a lot of time thinking about exception-customization. I like your idea. Please issue a PR with an according change (also because I wouldn't know how to do it correctly).
Regarding constness, if there is something which is not const, but should be const, go ahead and make a PR. Especially if it improves the overall usage.
Hi,
I noticed that the library by default just throws std::invalid_argument here
json-schema-validator/src/json-validator.cpp
Line 1302 in 89ed13d
I don't want to catch std::invalid_argument. I know I can provide my own error handler, but it looks identical to the default one except that it throws a subclass of std::invalid_argument.
So I wonder if the lib itself could not just do that by default?
A second thing I wondered:
json-schema-validator/src/nlohmann/json-schema.hpp
Line 142 in 89ed13d
Couldn't this member function made const and therefore every argument of validate made const too? This would allow to pass RValue to validate().
So
validate(j, MyHandler {});
The text was updated successfully, but these errors were encountered: