[petsc-users] ((PetscObject)M)->comm

Hui Zhang mike.hui.zhang at hotmail.com
Sat Feb 16 08:11:54 CST 2013


Why?  When I try to use ((PetscObject)M)->comm in my function as follows,

PetscErrorCode SetupDirectSolver(KSP *ksp, Mat M)
{

   KSPCreate(((PetscObject)M)->comm,ksp);

}

I got 

    error: dereferencing pointer to incomplete type


More information about the petsc-users mailing list