-
Notifications
You must be signed in to change notification settings - Fork 24
New issue
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
IsEmpty() should check for .empty()
, not .size() == 0
#14
Comments
Any update on this? |
Thanks for reporting! Is there a practical consequence to this? |
Yes, inability to check for "emptiness" of things that are not containers (custom smart pointers or wrappers, for example). |
Yes, that makes sense. Thanks. Right now, IsEmpty() is implemented as a special case of HasLength(). We need to promote IsEmpty() to using its own IsEmptyConstraint. |
Any update on this? |
I just looked into it in the hope that it would be simple. For example, C++11's |
This way, IsEmpty() can be used for, for example, std::forward_list which does not have a size() method. Fixes #14.
Update: The before-mentioned branch is already merged and deleted; it contained only preliminary work. I am now working on the issue in the issue-14 branch. |
No description provided.
The text was updated successfully, but these errors were encountered: