On Mon, Jan 14, 2013 at 11:17 AM, Barry Smith <bsmith at mcs.anl.gov> wrote:
> Note that even if you change it to an inline function it still will not > give the correct stack frame since it is not inside the > PetscFunctionBegin/End. > The point is that an inline function routine couldn't be called in a declaration, so it would force people to move it. You're right that it looks like it was only used incorrectly in the places fixed here. https://bitbucket.org/petsc/petsc-dev/commits/59c614dd5ce57f9497e794f6495fc91990a89274 > > Shouldn't we simply ban its use in the declarations part of the > routines? > I thought it was already banned and that nobody was paying attention, sort of like the // comments. > Note that its use in, for example, > > } else { > PetscBLASInt ione = 1; > PetscScalar aone = 1.0, azero = 0.0; > PetscBLASInt neqs = PetscBLASIntCast(bcgsl->ell-1); > > is legal since it is within a PetscBegin/Return block and the last > declaration given. > > A quick etags search found that it is being used correctly already almost > anywhere. The suspicious place is only in the documentation :-) > > Thus I say, fix the documentation and check that it is never used > incorrectly but don't change its form. > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.mcs.anl.gov/pipermail/petsc-dev/attachments/20130114/52302691/attachment-0001.html>