Actual source code: matmetisimpl.h
1: #pragma once
3: #define PetscCallMETIS(func, ...) \
4: do { \
5: int _status; \
6: PetscStackPushExternal(PetscStringize(func)); \
7: _status = func(__VA_ARGS__); \
8: PetscStackPop; \
9: PetscCheck(_status != METIS_ERROR_INPUT, PETSC_COMM_SELF, PETSC_ERR_LIB, "METIS error due to wrong inputs and/or options for %s", PetscStringize(func)); \
10: PetscCheck(_status != METIS_ERROR_MEMORY, PETSC_COMM_SELF, PETSC_ERR_MEM, "METIS error due to insufficient memory in %s", PetscStringize(func)); \
11: PetscCheck(_status != METIS_ERROR, PETSC_COMM_SELF, PETSC_ERR_LIB, "METIS general error in %s", PetscStringize(func)); \
12: } while (0)