Skip to content

Commit

Permalink
Make OptionSet bool operator const
Browse files Browse the repository at this point in the history
https://bugs.webkit.org/show_bug.cgi?id=259050

Reviewed by Darin Adler.

Make OptionSet bool operator const.

* Source/WTF/wtf/OptionSet.h:
(WTF::OptionSet::operator bool const):
(WTF::OptionSet::operator bool): Deleted.

Canonical link: https://commits.webkit.org/265905@main
  • Loading branch information
rwlbuis authored and darinadler committed Jul 10, 2023
1 parent 01329a3 commit 28cdfd0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Source/WTF/wtf/OptionSet.h
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ template<typename E> class OptionSet {
constexpr iterator begin() const { return m_storage; }
constexpr iterator end() const { return 0; }

constexpr explicit operator bool() { return !isEmpty(); }
constexpr explicit operator bool() const { return !isEmpty(); }

constexpr bool contains(E option) const
{
Expand Down

0 comments on commit 28cdfd0

Please sign in to comment.