SETERRA#

Fortran-only macro that can be called when an error has been detected from the main program

Synopsis#

#include <petscsys.h>
PetscErrorCode SETERRA(MPI_Comm comm,PetscErrorCode ierr,char *message)

Collective

Input Parameters#

  • comm - A communicator, so that the error can be collective

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

  • message - error message in the printf format

Notes#

This should only be used with Fortran. With C/C++, use SETERRQ().

Fortran Notes#

SETERRQ() may be called from Fortran subroutines but SETERRA() must be called from the Fortran main program.

See Also#

SETERRQ(), SETERRABORT(), PetscCall(), CHKERRA(), PetscCallAbort()

Level#

beginner

Location#

include/petscerror.h

Examples#

src/sys/tutorials/ex17f.F90.html
src/vec/vec/tutorials/ex14f.F90.html
src/vec/vec/tutorials/ex6f.F90.html
src/vec/vec/tutorials/ex9f.F90.html
src/vec/is/sf/tutorials/ex1f.F90.html
src/dm/impls/plex/tutorials/ex1f90.F90.html
src/ksp/ksp/tutorials/ex13f90.F90.html
src/ksp/ksp/tutorials/ex1f.F90.html
src/ksp/ksp/tutorials/ex77f.F90.html
src/ksp/ksp/tutorials/ex83f.F90.html
src/snes/tutorials/ex1f.F90.html


Edit on GitLab

Index of all Sys routines
Table of Contents for all manual pages
Index of all manual pages