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
One concept that is often useful in many types is a contextual conversion to bool. The following expressions should be valid with the concept:
if (o) {} if (!o) {} template <typename O> bool test(O&& o) { return o; }
Add a predefined concept that catches these requirement. A possible implementation:
namespace boost { namespace type_erasure { template<class T> struct testable { static bool apply(const T& arg) { return bool(arg); } }; template<class T, class Base> struct concept_interface<testable<T>, Base, T> : Base { explicit operator bool () const { return call(testable<T>(), *this); } }; }}
The text was updated successfully, but these errors were encountered:
No branches or pull requests
One concept that is often useful in many types is a contextual conversion to bool. The following expressions should be valid with the concept:
Add a predefined concept that catches these requirement. A possible implementation:
The text was updated successfully, but these errors were encountered: