diff options
| author | babenko <[email protected]> | 2022-10-27 20:26:32 +0300 |
|---|---|---|
| committer | babenko <[email protected]> | 2022-10-27 20:26:32 +0300 |
| commit | 83b8a0dc3ee65a7ea496298f9d8a427f920151d1 (patch) | |
| tree | be3c224ac1e22ba1afb5e6a336de4c11d88ff5d8 /library/cpp/yt/misc/preprocessor.h | |
| parent | 787835bd59a8743ef2cab69d02818038b1baa771 (diff) | |
Introduce PP_DEPAREN
Diffstat (limited to 'library/cpp/yt/misc/preprocessor.h')
| -rw-r--r-- | library/cpp/yt/misc/preprocessor.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/library/cpp/yt/misc/preprocessor.h b/library/cpp/yt/misc/preprocessor.h index 9afd3ae9021..719973c0f16 100644 --- a/library/cpp/yt/misc/preprocessor.h +++ b/library/cpp/yt/misc/preprocessor.h @@ -52,6 +52,15 @@ #define PP_EMPTY() //! \endcond +//! Removes the enclosing parens, if any. +#define PP_DEPAREN(...) PP_DEPAREN_A(PP_DEPAREN_C __VA_ARGS__) +//! \cond Implementation +#define PP_DEPAREN_C(...) PP_DEPAREN_C __VA_ARGS__ +#define PP_DEPAREN_A(...) PP_DEPAREN_B(__VA_ARGS__) +#define PP_DEPAREN_B(...) PP_DEPAREN_D_ ## __VA_ARGS__ +#define PP_DEPAREN_D_PP_DEPAREN_C +//! \endcond + //! Performs (non-lazy) conditional expansion. /*! * \param cond Condition; should expands to either \c PP_TRUE or \c PP_FALSE. |
