Skip to content
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

Add std::initializer_list constructor #31

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
23 changes: 23 additions & 0 deletions include/boost/bimap/bimap.hpp
Expand Up @@ -265,6 +265,29 @@ class bimap

{}

#ifndef BOOST_NO_CXX11_HDR_INITIALIZER_LIST
bimap(std::initializer_list<BOOST_DEDUCED_TYPENAME base_::core_type::value_type> init,
const allocator_type& al = allocator_type()) :

base_::relation_set(
::boost::multi_index::get<
BOOST_DEDUCED_TYPENAME base_::logic_relation_set_tag>(core)
),

core(init,ctor_args_list(),al),

left (
::boost::multi_index::get<
BOOST_DEDUCED_TYPENAME base_::logic_left_tag>(core)
),
right (
::boost::multi_index::get<
BOOST_DEDUCED_TYPENAME base_::logic_right_tag>(core)
)

{}
#endif

bimap(const bimap& x) :

base_::relation_set(
Expand Down