[Feature request] Add "contains" method to associative indexes, as of C++20
Closed this issue · 1 comments
fgallegosalido commented
C++20 added a new method to the associative containers, contains
, which takes a key and returns a boolean, indicating whether or not the element is in the container.
This releases us from using functions like count
or find
just for checking if the element is in the container, and be more explicit about our intentions.
As multi-index tries to be as similar as the STL counterparts, this is a logical addition.
joaquintides commented
Just added, will be released in Boost 1.78.