diff --git a/appveyor.yml b/appveyor.yml index 12e6b15..08a0ed0 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -14,6 +14,9 @@ branches: environment: matrix: + - APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2015 + TOOLSET: msvc-14.0 + ADDRMD: 32,64 - APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017 TOOLSET: msvc-14.1 ADDRMD: 32,64 diff --git a/include/boost/variant2/variant.hpp b/include/boost/variant2/variant.hpp index 3cd3275..a1ad459 100644 --- a/include/boost/variant2/variant.hpp +++ b/include/boost/variant2/variant.hpp @@ -1,12 +1,17 @@ #ifndef BOOST_VARIANT2_VARIANT_HPP_INCLUDED #define BOOST_VARIANT2_VARIANT_HPP_INCLUDED -// Copyright 2017 Peter Dimov. +// Copyright 2017, 2018 Peter Dimov. // -// Distributed under the Boost Software License, Version 1.0. +// Distributed under the Boost Software License, Version 1.0. // -// See accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt +// See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt + +#if defined(_MSC_VER) && _MSC_VER < 1910 +# pragma warning( push ) +# pragma warning( disable: 4521 4522 ) // multiple copy operators +#endif #ifndef BOOST_MP11_HPP_INCLUDED #include @@ -1028,7 +1033,7 @@ private: } else { - this_->variant_base::template emplace( r._get_impl( i ) ); + this_->variant_base::template emplace( r._get_impl( i ) ); } } }; @@ -1070,7 +1075,7 @@ private: } else { - this_->variant_base::template emplace( std::move( r._get_impl( i ) ) ); + this_->variant_base::template emplace( std::move( r._get_impl( i ) ) ); } } }; @@ -1485,9 +1490,9 @@ template struct visit_L1 F&& f; V1&& v1; - template auto operator()( I i ) const -> Vret + template auto operator()( I ) const -> Vret { - return std::forward(f)( get( std::forward(v1) ) ); + return std::forward(f)( get( std::forward(v1) ) ); } }; @@ -1556,4 +1561,8 @@ void swap( variant & v, variant & w ) } // namespace variant2 } // namespace boost +#if defined(_MSC_VER) && _MSC_VER < 1910 +# pragma warning( pop ) +#endif + #endif // #ifndef BOOST_VARIANT2_VARIANT_HPP_INCLUDED