1. petsc
  2. PETSc
  3. petsc

Branches

jed/defined-nocpp

View source
jed/defined-nocpp
  • Contributors
    1. Loading...
Author Commit Message Date Builds
250+ commits behind master.
Jed Brown
PetscDefined: test whether a configuration macro is defined without #ifdef This allows testing configuration macros from normal code, thus avoiding unused variable warnings and allowing the compiler to check for syntax errors throughout all alternatives. This use C99-style variadic macros. This trick was introduced by "comex" on Google+ in response to a question posed by Linus Torvalds. https://plus.google.com/+LinusTorvalds/posts/9gntjh57dXt