Avoid redefinition of macro functions (#4320)
author이한종/On-Device Lab(SR)/Engineer/삼성전자 <hanjoung.lee@samsung.com>
Fri, 25 Jan 2019 06:46:58 +0000 (15:46 +0900)
committer오형석/On-Device Lab(SR)/Staff Engineer/삼성전자 <hseok82.oh@samsung.com>
Fri, 25 Jan 2019 06:46:58 +0000 (15:46 +0900)
Avoid redefinition of CAST_CL and CAST_NE that generates warning.

Signed-off-by: Hanjoung Lee <hanjoung.lee@samsung.com>
libs/ARMComputeEx/arm_compute/runtime/misc/functions/Utils.h

index 04efe08..43df559 100644 (file)
@@ -46,8 +46,13 @@ namespace utils
  */
 bool isGpuMode();
 
-#define CAST_CL(tensor) static_cast<arm_compute::CLTensor *>(tensor)
-#define CAST_NE(tensor) static_cast<arm_compute::Tensor *>(tensor)
+#ifndef CAST_CL
+#define CAST_CL(tensor) static_cast<::arm_compute::CLTensor *>(tensor)
+#endif
+
+#ifndef CAST_NE
+#define CAST_NE(tensor) static_cast<::arm_compute::Tensor *>(tensor)
+#endif
 
 /**
  * @brief Class to represent arm compute axis