From d4a5e6b42c4bef40aa5411dbb49bca364a4846b7 Mon Sep 17 00:00:00 2001 From: Stephan Bergmann Date: Wed, 17 May 2017 11:31:51 +0200 Subject: Turn macro into function Change-Id: I6df7a287da74e49857e7fa3f0ba1cf67ab3bc74a --- opencl/source/opencl_device.cxx | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) (limited to 'opencl/source') diff --git a/opencl/source/opencl_device.cxx b/opencl/source/opencl_device.cxx index 9dc0130d6bad..fed84cfdf0c6 100644 --- a/opencl/source/opencl_device.cxx +++ b/opencl/source/opencl_device.cxx @@ -40,16 +40,17 @@ #define STRINGIFY(...) #__VA_ARGS__"\n" -#define DS_CHECK_STATUS(status, name) \ - if (CL_SUCCESS != status) \ - { \ - SAL_INFO("opencl.device", "Error code is " << status << " at " name); \ - } - namespace opencl { namespace { +void DS_CHECK_STATUS(cl_int status, char const * name) { + if (CL_SUCCESS != status) + { + SAL_INFO("opencl.device", "Error code is " << status << " at " << name); + } +} + bool bIsDeviceSelected = false; ds_device selectedDevice; -- cgit