xref: /petsc/include/petscdmceed.h (revision 5f80ce2ab25dff0f4601e710601cbbcecf323266)
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 CHKERRQ_CEED(PetscErrorCode);
11 #else
12 #define CHKERRQ_CEED(...)                                                                      \
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 
19 PETSC_EXTERN PetscErrorCode DMGetCeed(DM, Ceed *);
20 
21 #endif
22 
23 #endif
24