Apply clang-tidy fixes for bugprone-macro-parentheses in Interop.h (NFC)

This commit is contained in:
Mehdi Amini 2022-01-11 20:21:37 +00:00
parent ac5d32b103
commit 44bdcb889a
1 changed files with 2 additions and 1 deletions

View File

@ -96,7 +96,8 @@
/// Gets a void* from a wrapped struct. Needed because const cast is different /// Gets a void* from a wrapped struct. Needed because const cast is different
/// between C/C++. /// between C/C++.
#ifdef __cplusplus #ifdef __cplusplus
#define MLIR_PYTHON_GET_WRAPPED_POINTER(object) const_cast<void *>(object.ptr) #define MLIR_PYTHON_GET_WRAPPED_POINTER(object) \
(const_cast<void *>((object).ptr))
#else #else
#define MLIR_PYTHON_GET_WRAPPED_POINTER(object) (void *)(object.ptr) #define MLIR_PYTHON_GET_WRAPPED_POINTER(object) (void *)(object.ptr)
#endif #endif