forked from boostorg/container
Fixes #206 ("operator-> on static_vector::iterator causes cast alignment warning")
This commit is contained in:
1 parent
ea3521bf14
commit
3f76f9fdf7
23 files changed
+124
-93
No files matched your search
@@ -17,6 +17,7 @@
|
||||
#include <boost/container/detail/mpl.hpp>
|
||||
#include <boost/move/utility_core.hpp>
|
||||
#include <boost/container/detail/type_traits.hpp>
|
||||
#include <boost/move/detail/force_ptr.hpp> //adl_move_swap
|
||||
|
||||
namespace boost{
|
||||
namespace container {
|
||||
@@ -151,7 +152,7 @@ static boost::container::dtl::aligned_storage<sizeof(EmplaceIntPair)*10>::type p
|
||||
|
||||
static EmplaceIntPair* initialize_emplace_int_pair()
|
||||
{
|
||||
EmplaceIntPair* ret = reinterpret_cast<EmplaceIntPair*>(&pair_storage);
|
||||
EmplaceIntPair* ret = move_detail::force_ptr<EmplaceIntPair*>(&pair_storage);
|
||||
for(unsigned int i = 0; i != 10; ++i){
|
||||
new(&ret->first)EmplaceInt();
|
||||
new(&ret->second)EmplaceInt();
|
||||
|
||||
Reference in new issue
Block a user