urcu-pointer: implement URCU_FORCE_CAST for C++ compatibility of urcu-pointer.h
[urcu.git] / urcu / compiler.h
index 4bced2a9849846a25b8c1fd59a15cd2b03af0060..6db803e9319845a38d847f6ccc339c2230f55c91 100644 (file)
  */
 #define __rcu
 
+#ifdef __cplusplus
+#define URCU_FORCE_CAST(type, arg)     (reinterpret_cast<type>(arg))
+#else
+#define URCU_FORCE_CAST(type, arg)     ((type) (arg))
+#endif
+
 #endif /* _URCU_COMPILER_H */
This page took 0.022102 seconds and 4 git commands to generate.