boostorg / move

Boost.org move module
http://boost.org/libs/move
Boost Software License 1.0
19 stars 55 forks source link

MSVC warning C5243: 'boost::move_detail::member_function_ptr': using incomplete class 'boost::move_detail::alignment_dummy' can cause potential one definition rule violation due to ABI limitation #47

Closed Kojoley closed 2 years ago

Kojoley commented 2 years ago
boost/move/detail/type_traits.hpp(1128): warning C5243: 'boost::move_detail::member_function_ptr': using incomplete class 'boost::move_detail::alignment_dummy' can cause potential one definition rule violation due to ABI limitation
boost/move/detail/type_traits.hpp(1102): note: see declaration of 'boost::move_detail::alignment_dummy'
boost/move/detail/type_traits.hpp(1128): note: consider using inheritance keywords on the forward declaration of the class to avoid the issue: 'class [__single_inheritance|__multiple_inheritance|__virtual_inheritance] class-name;'

https://godbolt.org/z/5xEaKfYMn

igaztanaga commented 2 years ago

Many thanks for the report!

Kojoley commented 2 years ago

Thanks for fixing the warnings!

soroush commented 1 year ago

@igaztanaga Thanks for the fix Do you know of any workaround that doesn't involve updating the boost to the new version?

igaztanaga commented 1 year ago

I can see any workaround other than apply the patch to your local version:

https://github.com/boostorg/move/commit/dc9edc458cf1936511fc2e503469045e4d43ac31