mirror of
https://gitlab.kitware.com/vtk/vtk-m
synced 2024-09-16 17:22:55 +00:00
Always disable conversion warnings when including boost header files
On one of my compile platforms, GCC was giving conversion warnings from any boost include that was not wrapped in pragmas to disable conversion warnings. To make things easier and more robust, I created a pair of macros, VTKM_BOOST_PRE_INCLUDE and VTKM_BOOST_POST_INCLUDE, that should be wrapped around any #include of a boost header file.
This commit is contained in:
parent
5e5203d6be
commit
21b3b318ba
@ -24,8 +24,10 @@
|
|||||||
|
|
||||||
#include <vtkm/internal/ExportMacros.h>
|
#include <vtkm/internal/ExportMacros.h>
|
||||||
|
|
||||||
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
#include <boost/static_assert.hpp>
|
#include <boost/static_assert.hpp>
|
||||||
#include <boost/type_traits/is_base_of.hpp>
|
#include <boost/type_traits/is_base_of.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
|
|
||||||
namespace vtkm {
|
namespace vtkm {
|
||||||
|
|
||||||
|
@ -38,14 +38,17 @@
|
|||||||
// boost seems to want to undefine those macros so that it can implement the
|
// boost seems to want to undefine those macros so that it can implement the
|
||||||
// C99 templates and other implementations of the same name. Get around the
|
// C99 templates and other implementations of the same name. Get around the
|
||||||
// problem by using the boost version when compiling for a CPU.
|
// problem by using the boost version when compiling for a CPU.
|
||||||
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
#include <boost/math/special_functions/fpclassify.hpp>
|
#include <boost/math/special_functions/fpclassify.hpp>
|
||||||
#include <boost/math/special_functions/sign.hpp>
|
#include <boost/math/special_functions/sign.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
#include <cmath>
|
#include <cmath>
|
||||||
#define VTKM_USE_BOOST_CLASSIFY
|
#define VTKM_USE_BOOST_CLASSIFY
|
||||||
#define VTKM_USE_BOOST_SIGN
|
#define VTKM_USE_BOOST_SIGN
|
||||||
#endif // !VTKM_CUDA
|
#endif // !VTKM_CUDA
|
||||||
|
|
||||||
#if defined(VTKM_MSVC) && !defined(VTKM_CUDA)
|
#if defined(VTKM_MSVC) && !defined(VTKM_CUDA)
|
||||||
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
#include <boost/math/special_functions/acosh.hpp>
|
#include <boost/math/special_functions/acosh.hpp>
|
||||||
#include <boost/math/special_functions/asinh.hpp>
|
#include <boost/math/special_functions/asinh.hpp>
|
||||||
#include <boost/math/special_functions/atanh.hpp>
|
#include <boost/math/special_functions/atanh.hpp>
|
||||||
@ -53,6 +56,7 @@
|
|||||||
#include <boost/math/special_functions/expm1.hpp>
|
#include <boost/math/special_functions/expm1.hpp>
|
||||||
#include <boost/math/special_functions/log1p.hpp>
|
#include <boost/math/special_functions/log1p.hpp>
|
||||||
#include <boost/math/special_functions/round.hpp>
|
#include <boost/math/special_functions/round.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
#define VTKM_USE_BOOST_MATH
|
#define VTKM_USE_BOOST_MATH
|
||||||
#if _MSC_VER <= 1600
|
#if _MSC_VER <= 1600
|
||||||
#define VTKM_USE_STL_MIN_MAX
|
#define VTKM_USE_STL_MIN_MAX
|
||||||
|
@ -50,14 +50,17 @@ $# Ignore the following comment. It is meant for the generated file.
|
|||||||
// boost seems to want to undefine those macros so that it can implement the
|
// boost seems to want to undefine those macros so that it can implement the
|
||||||
// C99 templates and other implementations of the same name. Get around the
|
// C99 templates and other implementations of the same name. Get around the
|
||||||
// problem by using the boost version when compiling for a CPU.
|
// problem by using the boost version when compiling for a CPU.
|
||||||
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
#include <boost/math/special_functions/fpclassify.hpp>
|
#include <boost/math/special_functions/fpclassify.hpp>
|
||||||
#include <boost/math/special_functions/sign.hpp>
|
#include <boost/math/special_functions/sign.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
#include <cmath>
|
#include <cmath>
|
||||||
#define VTKM_USE_BOOST_CLASSIFY
|
#define VTKM_USE_BOOST_CLASSIFY
|
||||||
#define VTKM_USE_BOOST_SIGN
|
#define VTKM_USE_BOOST_SIGN
|
||||||
#endif // !VTKM_CUDA
|
#endif // !VTKM_CUDA
|
||||||
|
|
||||||
#if defined(VTKM_MSVC) && !defined(VTKM_CUDA)
|
#if defined(VTKM_MSVC) && !defined(VTKM_CUDA)
|
||||||
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
#include <boost/math/special_functions/acosh.hpp>
|
#include <boost/math/special_functions/acosh.hpp>
|
||||||
#include <boost/math/special_functions/asinh.hpp>
|
#include <boost/math/special_functions/asinh.hpp>
|
||||||
#include <boost/math/special_functions/atanh.hpp>
|
#include <boost/math/special_functions/atanh.hpp>
|
||||||
@ -65,6 +68,7 @@ $# Ignore the following comment. It is meant for the generated file.
|
|||||||
#include <boost/math/special_functions/expm1.hpp>
|
#include <boost/math/special_functions/expm1.hpp>
|
||||||
#include <boost/math/special_functions/log1p.hpp>
|
#include <boost/math/special_functions/log1p.hpp>
|
||||||
#include <boost/math/special_functions/round.hpp>
|
#include <boost/math/special_functions/round.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
#define VTKM_USE_BOOST_MATH
|
#define VTKM_USE_BOOST_MATH
|
||||||
#if _MSC_VER <= 1600
|
#if _MSC_VER <= 1600
|
||||||
#define VTKM_USE_STL_MIN_MAX
|
#define VTKM_USE_STL_MIN_MAX
|
||||||
|
@ -27,7 +27,9 @@
|
|||||||
#include <vtkm/cont/TopologyType.h>
|
#include <vtkm/cont/TopologyType.h>
|
||||||
#include <vtkm/cont/DeviceAdapterAlgorithm.h>
|
#include <vtkm/cont/DeviceAdapterAlgorithm.h>
|
||||||
|
|
||||||
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
#include <boost/static_assert.hpp>
|
#include <boost/static_assert.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
|
|
||||||
namespace vtkm {
|
namespace vtkm {
|
||||||
|
|
||||||
|
@ -24,10 +24,12 @@
|
|||||||
#include <vtkm/internal/Configure.h>
|
#include <vtkm/internal/Configure.h>
|
||||||
#include <vtkm/internal/ExportMacros.h>
|
#include <vtkm/internal/ExportMacros.h>
|
||||||
|
|
||||||
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
#include <boost/mpl/or.hpp>
|
#include <boost/mpl/or.hpp>
|
||||||
#include <boost/type_traits/is_floating_point.hpp>
|
#include <boost/type_traits/is_floating_point.hpp>
|
||||||
#include <boost/type_traits/is_signed.hpp>
|
#include <boost/type_traits/is_signed.hpp>
|
||||||
#include <boost/utility/enable_if.hpp>
|
#include <boost/utility/enable_if.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
* \namespace vtkm
|
* \namespace vtkm
|
||||||
|
@ -22,7 +22,9 @@
|
|||||||
|
|
||||||
#include <vtkm/Types.h>
|
#include <vtkm/Types.h>
|
||||||
|
|
||||||
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
#include <boost/type_traits/remove_const.hpp>
|
#include <boost/type_traits/remove_const.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
|
|
||||||
namespace vtkm {
|
namespace vtkm {
|
||||||
|
|
||||||
|
@ -37,7 +37,9 @@
|
|||||||
#include <vtkm/cont/testing/Testing.h>
|
#include <vtkm/cont/testing/Testing.h>
|
||||||
#include <vtkm/benchmarking/Benchmarker.h>
|
#include <vtkm/benchmarking/Benchmarker.h>
|
||||||
|
|
||||||
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
#include <boost/random.hpp>
|
#include <boost/random.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
|
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
#include <cmath>
|
#include <cmath>
|
||||||
|
@ -31,11 +31,13 @@
|
|||||||
#include <vtkm/cont/internal/ArrayHandleExecutionManager.h>
|
#include <vtkm/cont/internal/ArrayHandleExecutionManager.h>
|
||||||
#include <vtkm/cont/internal/DeviceAdapterTag.h>
|
#include <vtkm/cont/internal/DeviceAdapterTag.h>
|
||||||
|
|
||||||
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
#include <boost/concept_check.hpp>
|
#include <boost/concept_check.hpp>
|
||||||
#include <boost/mpl/not.hpp>
|
#include <boost/mpl/not.hpp>
|
||||||
#include <boost/smart_ptr/scoped_ptr.hpp>
|
#include <boost/smart_ptr/scoped_ptr.hpp>
|
||||||
#include <boost/smart_ptr/shared_ptr.hpp>
|
#include <boost/smart_ptr/shared_ptr.hpp>
|
||||||
#include <boost/type_traits/is_base_of.hpp>
|
#include <boost/type_traits/is_base_of.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
|
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
|
@ -28,7 +28,9 @@
|
|||||||
|
|
||||||
#include <vtkm/internal/FunctionInterface.h>
|
#include <vtkm/internal/FunctionInterface.h>
|
||||||
|
|
||||||
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
#include <boost/static_assert.hpp>
|
#include <boost/static_assert.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
|
|
||||||
#include <sstream>
|
#include <sstream>
|
||||||
|
|
||||||
|
@ -27,7 +27,9 @@
|
|||||||
#include <vtkm/cont/DynamicArrayHandle.h>
|
#include <vtkm/cont/DynamicArrayHandle.h>
|
||||||
#include <vtkm/cont/DeviceAdapterAlgorithm.h>
|
#include <vtkm/cont/DeviceAdapterAlgorithm.h>
|
||||||
|
|
||||||
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
#include <boost/type_traits/is_base_of.hpp>
|
#include <boost/type_traits/is_base_of.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
|
|
||||||
namespace vtkm {
|
namespace vtkm {
|
||||||
namespace cont {
|
namespace cont {
|
||||||
|
@ -29,8 +29,10 @@
|
|||||||
|
|
||||||
#include <vtkm/cont/internal/DynamicTransform.h>
|
#include <vtkm/cont/internal/DynamicTransform.h>
|
||||||
|
|
||||||
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
#include <boost/smart_ptr/shared_ptr.hpp>
|
#include <boost/smart_ptr/shared_ptr.hpp>
|
||||||
#include <boost/utility/enable_if.hpp>
|
#include <boost/utility/enable_if.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
|
|
||||||
namespace vtkm {
|
namespace vtkm {
|
||||||
namespace cont {
|
namespace cont {
|
||||||
|
@ -27,7 +27,9 @@
|
|||||||
#include <vtkm/cont/internal/DynamicTransform.h>
|
#include <vtkm/cont/internal/DynamicTransform.h>
|
||||||
#include <vtkm/cont/internal/SimplePolymorphicContainer.h>
|
#include <vtkm/cont/internal/SimplePolymorphicContainer.h>
|
||||||
|
|
||||||
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
#include <boost/smart_ptr/shared_ptr.hpp>
|
#include <boost/smart_ptr/shared_ptr.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
|
|
||||||
namespace vtkm {
|
namespace vtkm {
|
||||||
namespace cont {
|
namespace cont {
|
||||||
|
@ -27,7 +27,9 @@
|
|||||||
|
|
||||||
#include <vtkm/cont/internal/DynamicTransform.h>
|
#include <vtkm/cont/internal/DynamicTransform.h>
|
||||||
|
|
||||||
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
#include <boost/shared_ptr.hpp>
|
#include <boost/shared_ptr.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
|
|
||||||
namespace vtkm {
|
namespace vtkm {
|
||||||
namespace cont {
|
namespace cont {
|
||||||
|
@ -28,7 +28,11 @@
|
|||||||
#define VTKM_STORAGE VTKM_STORAGE_BASIC
|
#define VTKM_STORAGE VTKM_STORAGE_BASIC
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#include <vtkm/internal/ExportMacros.h>
|
||||||
|
|
||||||
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
#include <boost/static_assert.hpp>
|
#include <boost/static_assert.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
|
|
||||||
namespace vtkm {
|
namespace vtkm {
|
||||||
namespace cont {
|
namespace cont {
|
||||||
|
@ -20,8 +20,12 @@
|
|||||||
#ifndef vtk_m_cont_arg_ControlSignatureTagBase_h
|
#ifndef vtk_m_cont_arg_ControlSignatureTagBase_h
|
||||||
#define vtk_m_cont_arg_ControlSignatureTagBase_h
|
#define vtk_m_cont_arg_ControlSignatureTagBase_h
|
||||||
|
|
||||||
|
#include <vtkm/internal/ExportMacros.h>
|
||||||
|
|
||||||
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
#include <boost/static_assert.hpp>
|
#include <boost/static_assert.hpp>
|
||||||
#include <boost/type_traits/is_base_of.hpp>
|
#include <boost/type_traits/is_base_of.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
|
|
||||||
namespace vtkm {
|
namespace vtkm {
|
||||||
namespace cont {
|
namespace cont {
|
||||||
|
@ -26,8 +26,10 @@
|
|||||||
|
|
||||||
#include <vtkm/exec/ExecutionObjectBase.h>
|
#include <vtkm/exec/ExecutionObjectBase.h>
|
||||||
|
|
||||||
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
#include <boost/mpl/assert.hpp>
|
#include <boost/mpl/assert.hpp>
|
||||||
#include <boost/type_traits/is_base_of.hpp>
|
#include <boost/type_traits/is_base_of.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
|
|
||||||
namespace vtkm {
|
namespace vtkm {
|
||||||
namespace cont {
|
namespace cont {
|
||||||
|
@ -20,11 +20,15 @@
|
|||||||
#ifndef vtk_m_cont_arg_TypeCheckTagExecObject_h
|
#ifndef vtk_m_cont_arg_TypeCheckTagExecObject_h
|
||||||
#define vtk_m_cont_arg_TypeCheckTagExecObject_h
|
#define vtk_m_cont_arg_TypeCheckTagExecObject_h
|
||||||
|
|
||||||
|
#include <vtkm/internal/ExportMacros.h>
|
||||||
|
|
||||||
#include <vtkm/cont/arg/TypeCheck.h>
|
#include <vtkm/cont/arg/TypeCheck.h>
|
||||||
|
|
||||||
#include <vtkm/exec/ExecutionObjectBase.h>
|
#include <vtkm/exec/ExecutionObjectBase.h>
|
||||||
|
|
||||||
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
#include <boost/type_traits/is_base_of.hpp>
|
#include <boost/type_traits/is_base_of.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
|
|
||||||
namespace vtkm {
|
namespace vtkm {
|
||||||
namespace cont {
|
namespace cont {
|
||||||
|
@ -30,8 +30,10 @@
|
|||||||
|
|
||||||
#include <vtkm/exec/internal/ErrorMessageBuffer.h>
|
#include <vtkm/exec/internal/ErrorMessageBuffer.h>
|
||||||
|
|
||||||
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
#include <boost/iterator/counting_iterator.hpp>
|
#include <boost/iterator/counting_iterator.hpp>
|
||||||
#include <boost/utility/enable_if.hpp>
|
#include <boost/utility/enable_if.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
|
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
#include <numeric>
|
#include <numeric>
|
||||||
|
@ -25,7 +25,9 @@
|
|||||||
|
|
||||||
#include <string>
|
#include <string>
|
||||||
|
|
||||||
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
#include <boost/static_assert.hpp>
|
#include <boost/static_assert.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
|
|
||||||
#define VTKM_DEVICE_ADAPTER_ERROR -2
|
#define VTKM_DEVICE_ADAPTER_ERROR -2
|
||||||
#define VTKM_DEVICE_ADAPTER_UNDEFINED -1
|
#define VTKM_DEVICE_ADAPTER_UNDEFINED -1
|
||||||
|
@ -24,7 +24,9 @@
|
|||||||
|
|
||||||
#include <vtkm/cont/Assert.h>
|
#include <vtkm/cont/Assert.h>
|
||||||
|
|
||||||
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
#include <boost/iterator/iterator_facade.hpp>
|
#include <boost/iterator/iterator_facade.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
|
|
||||||
namespace vtkm {
|
namespace vtkm {
|
||||||
namespace cont {
|
namespace cont {
|
||||||
|
@ -22,8 +22,10 @@
|
|||||||
|
|
||||||
#include <vtkm/Types.h>
|
#include <vtkm/Types.h>
|
||||||
|
|
||||||
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
#include <boost/static_assert.hpp>
|
#include <boost/static_assert.hpp>
|
||||||
#include <boost/type_traits/is_base_of.hpp>
|
#include <boost/type_traits/is_base_of.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
|
|
||||||
/// Checks that the argument is a proper \c PointCoordinates class. This is a
|
/// Checks that the argument is a proper \c PointCoordinates class. This is a
|
||||||
/// handy concept check for functions and classes to make sure that a template
|
/// handy concept check for functions and classes to make sure that a template
|
||||||
|
@ -22,7 +22,9 @@
|
|||||||
|
|
||||||
#include <vtkm/Types.h>
|
#include <vtkm/Types.h>
|
||||||
|
|
||||||
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
#include <boost/smart_ptr/shared_ptr.hpp>
|
#include <boost/smart_ptr/shared_ptr.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
|
|
||||||
namespace vtkm {
|
namespace vtkm {
|
||||||
namespace cont {
|
namespace cont {
|
||||||
|
@ -32,7 +32,9 @@
|
|||||||
#include <vtkm/cont/ErrorExecution.h>
|
#include <vtkm/cont/ErrorExecution.h>
|
||||||
#include <vtkm/cont/internal/DeviceAdapterAlgorithmGeneral.h>
|
#include <vtkm/cont/internal/DeviceAdapterAlgorithmGeneral.h>
|
||||||
|
|
||||||
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
#include <boost/type_traits/remove_reference.hpp>
|
#include <boost/type_traits/remove_reference.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
|
|
||||||
// Disable warnings we check vtkm for but TBB does not.
|
// Disable warnings we check vtkm for but TBB does not.
|
||||||
#if defined(VTKM_GCC) || defined(VTKM_CLANG)
|
#if defined(VTKM_GCC) || defined(VTKM_CLANG)
|
||||||
|
@ -20,8 +20,12 @@
|
|||||||
#ifndef vtk_m_exec_arg_ExecutionSignatureTagBase_h
|
#ifndef vtk_m_exec_arg_ExecutionSignatureTagBase_h
|
||||||
#define vtk_m_exec_arg_ExecutionSignatureTagBase_h
|
#define vtk_m_exec_arg_ExecutionSignatureTagBase_h
|
||||||
|
|
||||||
|
#include <vtkm/internal/ExportMacros.h>
|
||||||
|
|
||||||
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
#include <boost/static_assert.hpp>
|
#include <boost/static_assert.hpp>
|
||||||
#include <boost/type_traits/is_base_of.hpp>
|
#include <boost/type_traits/is_base_of.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
|
|
||||||
namespace vtkm {
|
namespace vtkm {
|
||||||
namespace exec {
|
namespace exec {
|
||||||
|
@ -24,7 +24,9 @@
|
|||||||
#include <vtkm/exec/arg/Fetch.h>
|
#include <vtkm/exec/arg/Fetch.h>
|
||||||
#include <vtkm/exec/TopologyData.h>
|
#include <vtkm/exec/TopologyData.h>
|
||||||
|
|
||||||
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
#include <boost/type_traits.hpp>
|
#include <boost/type_traits.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
|
|
||||||
namespace vtkm {
|
namespace vtkm {
|
||||||
namespace exec {
|
namespace exec {
|
||||||
|
@ -25,8 +25,10 @@
|
|||||||
|
|
||||||
#include <vtkm/exec/ExecutionObjectBase.h>
|
#include <vtkm/exec/ExecutionObjectBase.h>
|
||||||
|
|
||||||
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
#include <boost/mpl/assert.hpp>
|
#include <boost/mpl/assert.hpp>
|
||||||
#include <boost/type_traits/is_base_of.hpp>
|
#include <boost/type_traits/is_base_of.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
|
|
||||||
namespace vtkm {
|
namespace vtkm {
|
||||||
namespace exec {
|
namespace exec {
|
||||||
|
@ -24,7 +24,9 @@
|
|||||||
#include <vtkm/cont/ArrayPortalToIterators.h>
|
#include <vtkm/cont/ArrayPortalToIterators.h>
|
||||||
|
|
||||||
#include <iterator>
|
#include <iterator>
|
||||||
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
#include <boost/type_traits/remove_const.hpp>
|
#include <boost/type_traits/remove_const.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
|
|
||||||
// Disable warnings we check vtkm for but Thrust does not.
|
// Disable warnings we check vtkm for but Thrust does not.
|
||||||
#if defined(VTKM_GCC) || defined(VTKM_CLANG)
|
#if defined(VTKM_GCC) || defined(VTKM_CLANG)
|
||||||
@ -39,8 +41,10 @@
|
|||||||
#pragma GCC diagnostic pop
|
#pragma GCC diagnostic pop
|
||||||
#endif // gcc || clang
|
#endif // gcc || clang
|
||||||
|
|
||||||
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
#include <boost/type_traits/integral_constant.hpp>
|
#include <boost/type_traits/integral_constant.hpp>
|
||||||
#include <boost/utility/enable_if.hpp>
|
#include <boost/utility/enable_if.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
|
|
||||||
namespace vtkm {
|
namespace vtkm {
|
||||||
namespace exec {
|
namespace exec {
|
||||||
|
@ -26,8 +26,10 @@
|
|||||||
|
|
||||||
#include <vtkm/testing/Testing.h>
|
#include <vtkm/testing/Testing.h>
|
||||||
|
|
||||||
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
#include <boost/mpl/assert.hpp>
|
#include <boost/mpl/assert.hpp>
|
||||||
#include <boost/type_traits/is_same.hpp>
|
#include <boost/type_traits/is_same.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
|
|
||||||
namespace {
|
namespace {
|
||||||
|
|
||||||
|
@ -103,24 +103,32 @@
|
|||||||
# endif
|
# endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
// Define a pair of macros, VTKM_BOOST_PRE_INCLUDE and VTKM_BOOST_POST_INCLUDE,
|
||||||
|
// that should be wrapped around any #include for a boost header file. Mostly
|
||||||
|
// this is used to set pragmas that dissable warnings that VTK-m checks for
|
||||||
|
// but boost does not.
|
||||||
|
#if defined(VTKM_GCC) || defined(VTKM_CLANG)
|
||||||
|
#define VTKM_BOOST_PRE_INCLUDE \
|
||||||
|
_Pragma("GCC diagnostic push") \
|
||||||
|
_Pragma("GCC diagnostic ignored \"-Wconversion\"")
|
||||||
|
#define VTKM_BOOST_POST_INCLUDE \
|
||||||
|
_Pragma("GCC diagnostic pop")
|
||||||
|
#else
|
||||||
|
#define VTKM_BOOST_PRE_INCLUDE
|
||||||
|
#define VTKM_BOOST_POST_INCLUDE
|
||||||
|
#endif
|
||||||
|
|
||||||
// Determine whether we will use variadic templates (a new feature in C++11).
|
// Determine whether we will use variadic templates (a new feature in C++11).
|
||||||
// Currently have VARIADIC_TEMPLATE support off.
|
// Currently have VARIADIC_TEMPLATE support off.
|
||||||
#cmakedefine VTKM_NO_VARIADIC_TEMPLATE
|
#cmakedefine VTKM_NO_VARIADIC_TEMPLATE
|
||||||
#if !defined(VTKM_USE_VARIADIC_TEMPLATE) && !defined(VTKM_NO_VARIADIC_TEMPLATE)
|
#if !defined(VTKM_USE_VARIADIC_TEMPLATE) && !defined(VTKM_NO_VARIADIC_TEMPLATE)
|
||||||
// Currently using Boost to determine support.
|
// Currently using Boost to determine support.
|
||||||
|
|
||||||
# if defined(VTKM_GCC) || defined(VTKM_CLANG)
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
# pragma GCC diagnostic push
|
|
||||||
# pragma GCC diagnostic ignored "-Wconversion"
|
|
||||||
# endif // gcc || clang
|
|
||||||
|
|
||||||
# include <boost/config.hpp>
|
# include <boost/config.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
|
|
||||||
|
|
||||||
# if defined(VTKM_GCC) || defined(VTKM_CLANG)
|
|
||||||
# pragma GCC diagnostic pop
|
|
||||||
# endif // gcc || clang
|
|
||||||
|
|
||||||
# if defined(BOOST_HAS_VARIADIC_TMPL)
|
# if defined(BOOST_HAS_VARIADIC_TMPL)
|
||||||
# define VTKM_USE_VARIADIC_TEMPLATE 1
|
# define VTKM_USE_VARIADIC_TEMPLATE 1
|
||||||
# endif
|
# endif
|
||||||
|
@ -25,12 +25,7 @@
|
|||||||
#include <vtkm/internal/IndexTag.h>
|
#include <vtkm/internal/IndexTag.h>
|
||||||
|
|
||||||
|
|
||||||
// Disable conversion warnings inside boost
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
# if defined(VTKM_GCC) || defined(VTKM_CLANG)
|
|
||||||
# pragma GCC diagnostic push
|
|
||||||
# pragma GCC diagnostic ignored "-Wconversion"
|
|
||||||
# endif // gcc || clang
|
|
||||||
|
|
||||||
#include <boost/function_types/components.hpp>
|
#include <boost/function_types/components.hpp>
|
||||||
#include <boost/function_types/function_arity.hpp>
|
#include <boost/function_types/function_arity.hpp>
|
||||||
#include <boost/function_types/function_type.hpp>
|
#include <boost/function_types/function_type.hpp>
|
||||||
@ -45,12 +40,9 @@
|
|||||||
#include <boost/mpl/less.hpp>
|
#include <boost/mpl/less.hpp>
|
||||||
#include <boost/mpl/push_back.hpp>
|
#include <boost/mpl/push_back.hpp>
|
||||||
#include <boost/utility/enable_if.hpp>
|
#include <boost/utility/enable_if.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
|
|
||||||
|
|
||||||
# if defined(VTKM_GCC) || defined(VTKM_CLANG)
|
|
||||||
# pragma GCC diagnostic pop
|
|
||||||
# endif // gcc || clang
|
|
||||||
|
|
||||||
|
|
||||||
#include <vtkm/internal/FunctionInterfaceDetailPre.h>
|
#include <vtkm/internal/FunctionInterfaceDetailPre.h>
|
||||||
|
|
||||||
|
@ -30,8 +30,10 @@
|
|||||||
#include <vtkm/Types.h>
|
#include <vtkm/Types.h>
|
||||||
#include <vtkm/internal/IndexTag.h>
|
#include <vtkm/internal/IndexTag.h>
|
||||||
|
|
||||||
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
#include <boost/function_types/function_type.hpp>
|
#include <boost/function_types/function_type.hpp>
|
||||||
#include <boost/mpl/at.hpp>
|
#include <boost/mpl/at.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
|
|
||||||
#define VTKM_MAX_FUNCTION_PARAMETERS 10
|
#define VTKM_MAX_FUNCTION_PARAMETERS 10
|
||||||
|
|
||||||
|
@ -42,8 +42,10 @@ $# Ignore the following comment. It is meant for the generated file.
|
|||||||
#include <vtkm/Types.h>
|
#include <vtkm/Types.h>
|
||||||
#include <vtkm/internal/IndexTag.h>
|
#include <vtkm/internal/IndexTag.h>
|
||||||
|
|
||||||
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
#include <boost/function_types/function_type.hpp>
|
#include <boost/function_types/function_type.hpp>
|
||||||
#include <boost/mpl/at.hpp>
|
#include <boost/mpl/at.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
|
|
||||||
$py(max_parameters=10)\
|
$py(max_parameters=10)\
|
||||||
#define VTKM_MAX_FUNCTION_PARAMETERS $(max_parameters)
|
#define VTKM_MAX_FUNCTION_PARAMETERS $(max_parameters)
|
||||||
|
@ -26,7 +26,9 @@
|
|||||||
#include <vtkm/TypeTraits.h>
|
#include <vtkm/TypeTraits.h>
|
||||||
#include <vtkm/VecTraits.h>
|
#include <vtkm/VecTraits.h>
|
||||||
|
|
||||||
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
#include <boost/static_assert.hpp>
|
#include <boost/static_assert.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
|
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
#include <sstream>
|
#include <sstream>
|
||||||
|
@ -26,7 +26,9 @@
|
|||||||
|
|
||||||
#include <vtkm/testing/Testing.h>
|
#include <vtkm/testing/Testing.h>
|
||||||
|
|
||||||
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
#include <boost/type_traits/remove_const.hpp>
|
#include <boost/type_traits/remove_const.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
|
|
||||||
namespace vtkm {
|
namespace vtkm {
|
||||||
namespace testing {
|
namespace testing {
|
||||||
|
@ -36,10 +36,12 @@
|
|||||||
|
|
||||||
#include <vtkm/exec/internal/WorkletInvokeFunctor.h>
|
#include <vtkm/exec/internal/WorkletInvokeFunctor.h>
|
||||||
|
|
||||||
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
#include <boost/mpl/assert.hpp>
|
#include <boost/mpl/assert.hpp>
|
||||||
#include <boost/static_assert.hpp>
|
#include <boost/static_assert.hpp>
|
||||||
#include <boost/type_traits/is_base_of.hpp>
|
#include <boost/type_traits/is_base_of.hpp>
|
||||||
#include <boost/utility/enable_if.hpp>
|
#include <boost/utility/enable_if.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
|
|
||||||
#include <sstream>
|
#include <sstream>
|
||||||
|
|
||||||
|
@ -24,7 +24,9 @@
|
|||||||
#include <vtkm/cont/testing/Testing.h>
|
#include <vtkm/cont/testing/Testing.h>
|
||||||
#include <vtkm/cont/testing/MakeTestDataSet.h>
|
#include <vtkm/cont/testing/MakeTestDataSet.h>
|
||||||
|
|
||||||
|
VTKM_BOOST_PRE_INCLUDE
|
||||||
#include <boost/shared_ptr.hpp>
|
#include <boost/shared_ptr.hpp>
|
||||||
|
VTKM_BOOST_POST_INCLUDE
|
||||||
|
|
||||||
namespace {
|
namespace {
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user