mirror of
https://github.com/boostorg/container.git
synced 2025-08-04 06:54:27 +02:00
Use BOOST_FALLTHROUGH instead of the broken typo version
This commit is contained in:
@@ -69,16 +69,12 @@ struct are_elements_contiguous< ::boost::move_iterator<It> >
|
|||||||
// predeclarations
|
// predeclarations
|
||||||
/////////////////////////
|
/////////////////////////
|
||||||
|
|
||||||
#ifndef BOOST_CONTAINER_VECTOR_ITERATOR_IS_POINTER
|
|
||||||
|
|
||||||
template<class Pointer>
|
template<class Pointer>
|
||||||
class vector_iterator;
|
class vector_iterator;
|
||||||
|
|
||||||
template<class Pointer>
|
template<class Pointer>
|
||||||
class vector_const_iterator;
|
class vector_const_iterator;
|
||||||
|
|
||||||
#endif //BOOST_CONTAINER_VECTOR_ITERATOR_IS_POINTER
|
|
||||||
|
|
||||||
} //namespace container_detail {
|
} //namespace container_detail {
|
||||||
} //namespace container {
|
} //namespace container {
|
||||||
|
|
||||||
@@ -97,8 +93,6 @@ namespace container_detail {
|
|||||||
//vector_[const_]iterator
|
//vector_[const_]iterator
|
||||||
/////////////////////////
|
/////////////////////////
|
||||||
|
|
||||||
#ifndef BOOST_CONTAINER_VECTOR_ITERATOR_IS_POINTER
|
|
||||||
|
|
||||||
template<class Pointer>
|
template<class Pointer>
|
||||||
struct are_elements_contiguous<boost::container::container_detail::vector_iterator<Pointer> >
|
struct are_elements_contiguous<boost::container::container_detail::vector_iterator<Pointer> >
|
||||||
{
|
{
|
||||||
@@ -111,8 +105,6 @@ struct are_elements_contiguous<boost::container::container_detail::vector_const_
|
|||||||
static const bool value = true;
|
static const bool value = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif //BOOST_CONTAINER_VECTOR_ITERATOR_IS_POINTER
|
|
||||||
|
|
||||||
/////////////////////////
|
/////////////////////////
|
||||||
// offset_ptr
|
// offset_ptr
|
||||||
/////////////////////////
|
/////////////////////////
|
||||||
@@ -1073,21 +1065,21 @@ inline typename container_detail::enable_if_c
|
|||||||
std::memcpy(short_ptr, stora_ptr, sizeof_storage);
|
std::memcpy(short_ptr, stora_ptr, sizeof_storage);
|
||||||
large_ptr += sizeof_storage;
|
large_ptr += sizeof_storage;
|
||||||
short_ptr += sizeof_storage;
|
short_ptr += sizeof_storage;
|
||||||
BOOST_CONTAINER_FALLTHOUGH
|
BOOST_FALLTHROUGH;
|
||||||
case 3:
|
case 3:
|
||||||
std::memcpy(stora_ptr, large_ptr, sizeof_storage);
|
std::memcpy(stora_ptr, large_ptr, sizeof_storage);
|
||||||
std::memcpy(large_ptr, short_ptr, sizeof_storage);
|
std::memcpy(large_ptr, short_ptr, sizeof_storage);
|
||||||
std::memcpy(short_ptr, stora_ptr, sizeof_storage);
|
std::memcpy(short_ptr, stora_ptr, sizeof_storage);
|
||||||
large_ptr += sizeof_storage;
|
large_ptr += sizeof_storage;
|
||||||
short_ptr += sizeof_storage;
|
short_ptr += sizeof_storage;
|
||||||
BOOST_CONTAINER_FALLTHOUGH
|
BOOST_FALLTHROUGH;
|
||||||
case 2:
|
case 2:
|
||||||
std::memcpy(stora_ptr, large_ptr, sizeof_storage);
|
std::memcpy(stora_ptr, large_ptr, sizeof_storage);
|
||||||
std::memcpy(large_ptr, short_ptr, sizeof_storage);
|
std::memcpy(large_ptr, short_ptr, sizeof_storage);
|
||||||
std::memcpy(short_ptr, stora_ptr, sizeof_storage);
|
std::memcpy(short_ptr, stora_ptr, sizeof_storage);
|
||||||
large_ptr += sizeof_storage;
|
large_ptr += sizeof_storage;
|
||||||
short_ptr += sizeof_storage;
|
short_ptr += sizeof_storage;
|
||||||
BOOST_CONTAINER_FALLTHOUGH
|
BOOST_FALLTHROUGH;
|
||||||
case 1:
|
case 1:
|
||||||
std::memcpy(stora_ptr, large_ptr, sizeof_storage);
|
std::memcpy(stora_ptr, large_ptr, sizeof_storage);
|
||||||
std::memcpy(large_ptr, short_ptr, sizeof_storage);
|
std::memcpy(large_ptr, short_ptr, sizeof_storage);
|
||||||
|
@@ -43,12 +43,6 @@
|
|||||||
# endif
|
# endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if !defined(BOOST_FALLTHOUGH)
|
|
||||||
#define BOOST_CONTAINER_FALLTHOUGH
|
|
||||||
#else
|
|
||||||
#define BOOST_CONTAINER_FALLTHOUGH BOOST_FALLTHOUGH;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#if defined(BOOST_MSVC) && (_MSC_VER < 1400)
|
#if defined(BOOST_MSVC) && (_MSC_VER < 1400)
|
||||||
#define BOOST_CONTAINER_TEMPLATED_CONVERSION_OPERATOR_BROKEN
|
#define BOOST_CONTAINER_TEMPLATED_CONVERSION_OPERATOR_BROKEN
|
||||||
#endif
|
#endif
|
||||||
|
Reference in New Issue
Block a user