mirror of
https://github.com/boostorg/hana.git
synced 2026-02-01 08:32:11 +00:00
[Searchable] Refactor the interface
- Rename elem to contains - Rename subset to is_subset, and make is_subset applicable in infix notation - Add the at_key method - operator[] is now bound to at_key instead of find
This commit is contained in:
@@ -13,7 +13,7 @@ using namespace boost::hana;
|
||||
|
||||
|
||||
int main() {
|
||||
BOOST_HANA_CONSTEXPR_LAMBDA auto xs = set(1, 2.2, 'x');
|
||||
BOOST_HANA_CONSTEXPR_CHECK(elem(xs, 'x'));
|
||||
constexpr auto xs = set(1, 2.2, 'x');
|
||||
static_assert(contains(xs, 'x'), "");
|
||||
}
|
||||
//! [main]
|
||||
|
||||
Reference in New Issue
Block a user