Browse Source

add NR_EXPR to nr/macros.h if CPLUSPLUS is enabled

master
Niklas Rosenstein 2 years ago
parent
commit
7090c09628
Signed by: NiklasRosenstein GPG Key ID: 06D269B33D25F6C6
1 changed files with 7 additions and 0 deletions
  1. + 7
    - 0
      include/NiklasRosenstein/macros.h

+ 7
- 0
include/NiklasRosenstein/macros.h

@ -155,3 +155,10 @@
#elif !defined(NR_PLATFORM)
#warning "Unable to identify this platform, macro NR_PLATFORM stays undefined."
#endif
#ifdef __cplusplus
#define NR_EXPR(expr) ([&]() expr)()
#endif

Loading…
Cancel
Save