:orphan: # PetscStackUpdateLine in a function that has a `PetscFunctionBegin` or `PetscFunctionBeginUser` updates the stack line number to the current line number. ## Synopsis ``` #include void PetscStackUpdateLine ``` Not Collective ## Notes Using `PetscCall()` and friends automatically handles this process In debug mode PETSc maintains a stack of the current function calls that can be used to help to quickly see where a problem has occurred, for example, when a signal is received. It is recommended to use the debugger if extensive information is needed to help debug the problem. The default stack is a global variable called petscstack. This is used by `PetscCall()` and is otherwise not like to be needed ## See Also `PetscAttachDebugger()`, `PetscStackCopy()`, `PetscStackView()`, `PetscStackPushNoCheck()`, `PetscStackPop`, `PetscCall()` ## Level developer ## Location include/petscerror.h --- [Edit on GitLab](https://gitlab.com/petsc/petsc/-/edit/release/include/petscerror.h) [Index of all Sys routines](index.md) [Table of Contents for all manual pages](/manualpages/index.md) [Index of all manual pages](/manualpages/singleindex.md)