We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Handlers like readstat_set_variable_handler return an integer error code, but the three available error codes are defined as an enum:
readstat_set_variable_handler
enum { READSTAT_HANDLER_OK, READSTAT_HANDLER_ABORT, READSTAT_HANDLER_SKIP_VARIABLE };
As a result when registering a handler as a lambda function, I need a cast to avoid compilation errors:
readstat_set_variable_handler(parser, [](int, readstat_variable_t*, const char*, void*) { return static_cast<int>(READSTAT_HANDLER_OK); });
While it would make sense to be able to write:
readstat_set_variable_handler(parser, [](int, readstat_variable_t*, const char*, void*) { return READSTAT_HANDLER_OK; });
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Handlers like
readstat_set_variable_handler
return an integer error code, but the three available error codes are defined as an enum:As a result when registering a handler as a lambda function, I need a cast to avoid compilation errors:
While it would make sense to be able to write:
The text was updated successfully, but these errors were encountered: