1 #if !defined(PETSCDMCEED_H) 2 #define PETSCDMCEED_H 3 4 #include <petscdm.h> 5 6 #if defined(PETSC_HAVE_LIBCEED) 7 #include <ceed.h> 8 9 #if defined(PETSC_CLANG_STATIC_ANALYZER) 10 void PetscCallCEED(PetscErrorCode); 11 #else 12 #define PetscCallCEED(...) \ 13 do { \ 14 PetscErrorCode ierr_ceed_ = __VA_ARGS__; \ 15 PetscCheck(ierr_ceed_ == CEED_ERROR_SUCCESS, PETSC_COMM_SELF, PETSC_ERR_LIB, "libCEED error: %s", CeedErrorTypes[ierr_ceed_]); \ 16 } while (0) 17 #endif /* PETSC_CLANG_STATIC_ANALYZER */ 18 #define CHKERRQ_CEED(...) PetscCallCEED(__VA_ARGS__) 19 20 PETSC_EXTERN PetscErrorCode DMGetCeed(DM, Ceed *); 21 22 #endif 23 24 #endif 25