[petsc-dev] I question the existence of PetscErrorCode (*createlocaltoglobalmapping)(DM); PetscErrorCode (*createlocaltoglobalmappingblock)(DM);

Jed Brown jedbrown at mcs.anl.gov
Wed Mar 20 09:14:48 CDT 2013


On Wed, Mar 20, 2013 at 9:02 AM, Barry Smith <bsmith at mcs.anl.gov> wrote:

>    This is wrong and needs fixing, having one name for the public
> interface and a different name in the function table. You need to change
> the name in the function table to get() and
> DMCreateLocalToGlobalMapping_Composite() and friends to use the name DMGet…
>

That would imply that each DM* implementation would need to manage caching,
which is a bit of boilerplate, but perhaps okay in the interest of
consistency. Or do we start/reinforce a convention that some implementation
Get methods are called at most once because the outer part manages caching?


>    Having this inconsistent naming already wasted my time, and your time
> responding to the email and everyone else's time in having to delete the
> email. I'd fix it but git workflow is too hard so you need to fix it.
> Consistency reduces complexity.
>

I don't mind making the change, but here's the process to get a new branch
into 'next':

$ git checkout -b name/dmgetlocaltoglobalmapping master
change source, test, and commit
$ git checkout next
$ git merge name/dmgetlocaltoglobalmapping
$ test
$ git push origin next name/dmgetlocaltoglobalmapping
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-dev/attachments/20130320/2d3aee7f/attachment.html>


More information about the petsc-dev mailing list