Commit Graph

4 Commits

Author SHA1 Message Date
Kenneth Moreland
349799fa81 Fix static assert for visual studio
For some reason on my Visual Studio 2013 the definition of
VTKM_STATIC_ASSERT (without the message) did not report where the actual
error message happened. This change seems to get Visual Studio to report
the location of the failed assert with a reasonable message.
2016-11-23 13:10:56 -07:00
Robert Maynard
7acbdfa0ea Update StaticAssert.h to use the c++11 static_assert function 2016-09-01 09:35:43 -04:00
Kenneth Moreland
bfb26cf71b Do not use _Pragma in code blocks with CUDA
The current CUDA compiler is crashing when using _Pragma in code blocks,
which were being used with clang on apple. Turn these off when compiling
with CUDA.
2015-10-07 15:40:44 -06:00
Kenneth Moreland
b15940c1e3 Declare new VTKM_STATIC_ASSERT
This is to be used in place of BOOST_STATIC_ASSERT so that we can
control its implementation.

The implementation is designed to fix the issue where the latest XCode
clang compiler gives a warning about a unused typedefs when the boost
static assert is used within a function. (This warning also happens when
using the C++11 static_assert keyword.) You can suppress this warning
with _Pragma commands, but _Pragma commands inside a block is not
supported in GCC. The implementation of VTKM_STATIC_ASSERT handles all
current cases.
2015-09-17 14:40:39 -06:00