[petsc-users] Compilation error with ifort: invalid return statement in main

Praveen C cpraveen at gmail.com
Sun Nov 19 10:47:40 CST 2017


Thank you for this solution. For now, I am using this

call PetscInitialize(PETSC_NULL_CHARACTER,ierr)
if (ierr .ne. 0) stop 'Unable to initialize PETSc'

and CHKERRA in other places of main.

Best
praveen

> On 19-Nov-2017, at 9:18 PM, Smith, Barry F. <bsmith at mcs.anl.gov> wrote:
> 
>      In some of the Fortran examples we have code like
> 
>      call PetscInitialize(PETSC_NULL_CHARACTER,ierr)
>      if (ierr .ne. 0) then
>         print*,'Unable to initialize PETSc'
>         stop
>      endif
> 
>      Eventually we should update all the examples with this, or something even better.
> 
>   Barry

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20171119/0d02c449/attachment-0001.html>


More information about the petsc-users mailing list