petsc-3.12.5 2020-03-29
Report Typos and Errors

CHKERRXX

Checks error code, if non-zero it calls the C++ error handler which throws an exception

Synopsis

#include <petscsys.h>
void CHKERRXX(PetscErrorCode ierr)
Not Collective

Input Parameters

ierr -nonzero error code, see the list of standard error codes in include/petscerror.h

Notes

Once the error handler throws a ??? exception.

You can use CHKERRV() which returns without an error code (bad idea since the error is ignored) or CHKERRABORT(comm,n) to have MPI_Abort() returned immediately.

See Also

PetscTraceBackErrorHandler(), PetscPushErrorHandler(), PetscError(), SETERRQ(), CHKERRQ(), CHKMEMQ

Level

beginner

Location

src/sys/error/../../../include/petscerror.h
Index of all Sys routines
Table of Contents for all manual pages
Index of all manual pages