ISLocalToGlobalMappingApply(mapping,m,input,output); and alike "functions"

Barry Smith bsmith at mcs.anl.gov
Tue Oct 23 16:22:39 CDT 2007


  This is a known problem. I think the correct solution is to replace all the
"macro functions" with PETSC_STATIC_INLINE functions.

  I have done this in petsc-dev 
http://www-unix.mcs.anl.gov/petsc/petsc-as/developers/index.html


  Barry

On Thu, 11 Oct 2007, Mads Hoel wrote:

> Hi all,
> 
> I been having trouble with this function today. I called it from a function
> returning a void. Later found out it was actually
> a macro with a "return
> PetscError(__LINE__,__FUNCT__,__FILE__,__SDIR__,n,1,s,a1,a2,a3);" statement in
> it. Which makes it
> not possible to call ISLocalToGlobalMappingApply from a function returning a
> void, when compiling with g++ compiler.
> Or perhaps it may lead to difficult to find error in functions returning
> another type than an int, for example an object with
> a constructor accepting an int.
> 
> Thanks
> 
> 




More information about the petsc-dev mailing list