1 /* Copyright 2017 Joaquin M Lopez Munoz.
2 * Distributed under the Boost Software License, Version 1.0.
3 * (See accompanying file LICENSE_1_0.txt or copy at
4 * http://www.boost.org/LICENSE_1_0.txt)
6 * See http://www.boost.org/libs/poly_collection for library home page.
9 #ifndef BOOST_POLY_COLLECTION_DETAIL_WORKAROUND_DR1467_HPP
10 #define BOOST_POLY_COLLECTION_DETAIL_WORKAROUND_DR1467_HPP
16 #include <boost/config.hpp>
17 #include <boost/detail/workaround.hpp>
19 #if BOOST_WORKAROUND(BOOST_GCC_VERSION,<50000)||\
20 defined(BOOST_CLANG)&&\
21 (__clang_major__<3||(__clang_major__==3&&__clang_minor__<=6))
22 /* Defect report 1467 denounces that for aggregate types an intended {}-style
23 * copy construction will be mistaken for aggregate initialization:
24 * http://www.open-std.org/jtc1/sc22/wg21/docs/cwg_defects.html#1467
26 * A solution is to define a default constructor for the offending class so
27 * that it is no longer an aggregate.
30 #define BOOST_POLY_COLLECTION_WORKAROUND_DR1467(name) name(){}
32 #define BOOST_POLY_COLLECTION_WORKAROUND_DR1467(name)