From eb68e4725a1d64860aa945a6ba32f4876bb2e611 Mon Sep 17 00:00:00 2001 From: Peter Dimov Date: Sat, 28 Apr 2018 20:32:16 +0300 Subject: [PATCH] Add parentheses to BOOST_CUDA_VERSION Expressions like `BOOST_CUDA_VERSION / 1000000` don't work correctly; add parentheses around the expression to fix. --- include/boost/config/compiler/nvcc.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/boost/config/compiler/nvcc.hpp b/include/boost/config/compiler/nvcc.hpp index f21b9b54..64909409 100644 --- a/include/boost/config/compiler/nvcc.hpp +++ b/include/boost/config/compiler/nvcc.hpp @@ -12,7 +12,7 @@ #endif #if defined(__CUDACC_VER_MAJOR__) && defined(__CUDACC_VER_MINOR__) && defined(__CUDACC_VER_BUILD__) -# define BOOST_CUDA_VERSION __CUDACC_VER_MAJOR__ * 1000000 + __CUDACC_VER_MINOR__ * 10000 + __CUDACC_VER_BUILD__ +# define BOOST_CUDA_VERSION (__CUDACC_VER_MAJOR__ * 1000000 + __CUDACC_VER_MINOR__ * 10000 + __CUDACC_VER_BUILD__) #else // We don't really know what the CUDA version is, but it's definitely before 7.5: # define BOOST_CUDA_VERSION 7000000