mirror of
https://github.com/boostorg/array.git
synced 2025-07-31 13:17:21 +02:00
Suppress MSVC unreachable code warnings
This commit is contained in:
@ -40,6 +40,7 @@
|
|||||||
# pragma warning(disable: 4510) // boost::array<T,N>' : default constructor could not be generated
|
# pragma warning(disable: 4510) // boost::array<T,N>' : default constructor could not be generated
|
||||||
# pragma warning(disable: 4512) // boost::array<T,N>' : assignment operator could not be generated
|
# pragma warning(disable: 4512) // boost::array<T,N>' : assignment operator could not be generated
|
||||||
# pragma warning(disable: 4610) // class 'boost::array<T,N>' can never be instantiated - user defined constructor required
|
# pragma warning(disable: 4610) // class 'boost::array<T,N>' can never be instantiated - user defined constructor required
|
||||||
|
# pragma warning(disable: 4702) // unreachable code
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#include <boost/assert.hpp>
|
#include <boost/assert.hpp>
|
||||||
|
@ -4,11 +4,15 @@
|
|||||||
|
|
||||||
#define BOOST_ALLOW_DEPRECATED_SYMBOLS
|
#define BOOST_ALLOW_DEPRECATED_SYMBOLS
|
||||||
|
|
||||||
|
// assign is a deprecated nonstandard equivalent of fill
|
||||||
|
|
||||||
#include <boost/array.hpp>
|
#include <boost/array.hpp>
|
||||||
#include <boost/core/lightweight_test.hpp>
|
#include <boost/core/lightweight_test.hpp>
|
||||||
#include <cstddef>
|
#include <cstddef>
|
||||||
|
|
||||||
// assign is a deprecated nonstandard equivalent of fill
|
#if defined(_MSC_VER)
|
||||||
|
# pragma warning(disable: 4702) // unreachable code
|
||||||
|
#endif
|
||||||
|
|
||||||
template<class T, std::size_t N> void test()
|
template<class T, std::size_t N> void test()
|
||||||
{
|
{
|
||||||
|
@ -6,6 +6,10 @@
|
|||||||
#include <boost/core/lightweight_test.hpp>
|
#include <boost/core/lightweight_test.hpp>
|
||||||
#include <cstddef>
|
#include <cstddef>
|
||||||
|
|
||||||
|
#if defined(_MSC_VER)
|
||||||
|
# pragma warning(disable: 4702) // unreachable code
|
||||||
|
#endif
|
||||||
|
|
||||||
template<class T, std::size_t N> void test()
|
template<class T, std::size_t N> void test()
|
||||||
{
|
{
|
||||||
{
|
{
|
||||||
|
@ -6,6 +6,10 @@
|
|||||||
#include <boost/core/lightweight_test.hpp>
|
#include <boost/core/lightweight_test.hpp>
|
||||||
#include <cstddef>
|
#include <cstddef>
|
||||||
|
|
||||||
|
#if defined(_MSC_VER)
|
||||||
|
# pragma warning(disable: 4702) // unreachable code
|
||||||
|
#endif
|
||||||
|
|
||||||
template<class T, std::size_t N> void test()
|
template<class T, std::size_t N> void test()
|
||||||
{
|
{
|
||||||
boost::array<T, N> a = {};
|
boost::array<T, N> a = {};
|
||||||
|
@ -8,6 +8,10 @@
|
|||||||
#include <boost/config/workaround.hpp>
|
#include <boost/config/workaround.hpp>
|
||||||
#include <cstddef>
|
#include <cstddef>
|
||||||
|
|
||||||
|
#if defined(_MSC_VER)
|
||||||
|
# pragma warning(disable: 4702) // unreachable code
|
||||||
|
#endif
|
||||||
|
|
||||||
template<class T, std::size_t N> void test1()
|
template<class T, std::size_t N> void test1()
|
||||||
{
|
{
|
||||||
boost::array<T, N> a = {{}};
|
boost::array<T, N> a = {{}};
|
||||||
|
@ -6,6 +6,10 @@
|
|||||||
#include <boost/core/lightweight_test.hpp>
|
#include <boost/core/lightweight_test.hpp>
|
||||||
#include <cstddef>
|
#include <cstddef>
|
||||||
|
|
||||||
|
#if defined(_MSC_VER)
|
||||||
|
# pragma warning(disable: 4702) // unreachable code
|
||||||
|
#endif
|
||||||
|
|
||||||
template<class T, std::size_t N> void test()
|
template<class T, std::size_t N> void test()
|
||||||
{
|
{
|
||||||
{
|
{
|
||||||
|
@ -6,6 +6,10 @@
|
|||||||
#include <boost/core/lightweight_test.hpp>
|
#include <boost/core/lightweight_test.hpp>
|
||||||
#include <cstddef>
|
#include <cstddef>
|
||||||
|
|
||||||
|
#if defined(_MSC_VER)
|
||||||
|
# pragma warning(disable: 4702) // unreachable code
|
||||||
|
#endif
|
||||||
|
|
||||||
template<class T, std::size_t N> void test()
|
template<class T, std::size_t N> void test()
|
||||||
{
|
{
|
||||||
boost::array<T, N> a1 = {};
|
boost::array<T, N> a1 = {};
|
||||||
|
@ -6,6 +6,10 @@
|
|||||||
#include <boost/core/lightweight_test.hpp>
|
#include <boost/core/lightweight_test.hpp>
|
||||||
#include <cstddef>
|
#include <cstddef>
|
||||||
|
|
||||||
|
#if defined(_MSC_VER)
|
||||||
|
# pragma warning(disable: 4702) // unreachable code
|
||||||
|
#endif
|
||||||
|
|
||||||
template<class T, std::size_t N> void test()
|
template<class T, std::size_t N> void test()
|
||||||
{
|
{
|
||||||
boost::array<T, N> a1 = {};
|
boost::array<T, N> a1 = {};
|
||||||
|
Reference in New Issue
Block a user