Fix boost::array test for Visual Studio
Visual Studio doesn't set __cplusplus correctly when supporting c++11
This commit is contained in:
parent
8c96b0de0b
commit
3bfffab9f9
1 changed files with 7 additions and 7 deletions
|
|
@ -8,17 +8,17 @@
|
||||||
// and pointers to boost::array are the same.
|
// and pointers to boost::array are the same.
|
||||||
|
|
||||||
%{
|
%{
|
||||||
#if __cplusplus < 201103
|
#if __cplusplus >= 201103 || (defined(_MSC_VER) && _MSC_VER >= 1900)
|
||||||
#include <boost/array.hpp>
|
// Use C++11 array as this is unfortunately sometimes included by <algorithm>
|
||||||
namespace std {
|
|
||||||
using boost::array;
|
|
||||||
}
|
|
||||||
#else
|
|
||||||
// Use C++11 array as this is unfortunately is sometimes included by <algorithm>
|
|
||||||
#include <array>
|
#include <array>
|
||||||
namespace boost {
|
namespace boost {
|
||||||
using std::array;
|
using std::array;
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
#include <boost/array.hpp>
|
||||||
|
namespace std {
|
||||||
|
using boost::array;
|
||||||
|
}
|
||||||
#endif
|
#endif
|
||||||
%}
|
%}
|
||||||
namespace boost {
|
namespace boost {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue