#797: N13CarpetRegrid211snap_coarseE does not hold after being enforced in cell centering ---------------------+------------------------------------------------------ Reporter: rhaas | Owner: sbrandt Type: defect | Status: assigned Priority: major | Milestone: Component: Carpet | Version: Resolution: | Keywords: ---------------------+------------------------------------------------------ Changes (by eschnett):
* owner: eschnett => sbrandt * status: review => assigned
Comment:
This patch fails for me when I build with DEBUG=yes. The errors look like
/home/eschnett/Cvanilla/src/include/cctk.h(309): error: identifier "CCTK_THORNSTRING" is undefined __LINE__, __FILE__, CCTK_THORNSTRING,
compilation aborted for /home/eschnett/Cvanilla/configs/sim- debug/build/CactusBindings/Variables/ADM.c (code 2)
This is because the auto-generated file ADM.c includes cctk, which defines static inline functions that use CCTK_THORNSTRING. However, at the including place this is not defined.
I can see three solutions: (1) require every place that include cctk.h to define CCTK_THORNSTRING (possibly explicitly) (2) augment definethisthorn.h to define CCTK_THORNSTRING to "no thorn active" if no thorn is active (3) put some preprocessor logic into cctk.h to ensure CCTK_THORNSTRING is defined there