[dune-pdelab] [dune-pdelab-commit] [Commit] dune-pdelab - 1ed50f5: [Bugfix] Use freestanding TypeTree::child() when it might get passed an empty TreePath

Steffen Müthing steffen.muething at iwr.uni-heidelberg.de
Wed Sep 16 13:58:38 CEST 2015


> Am 16.09.2015 um 12:05 schrieb Christian Engwer <christian.engwer at uni-muenster.de>:
> 
> Hi Steffen,
> 
> regarding your latest changes in typetree (which I think as a reat
> improvement) I think that we should drop the ".child" method, as it
> seems to be kind of error-prone.

Yeah, I’ve been wondering about that as well, but it’s such a nice usability thing for end users:

TypeTree::child(node,_2,3,_4)

just isn’t as pretty as

node.child(_2,3,_4)

I hope I’ve got the issues ironed out now (we’ll have to communicate that writers of TypeTree-based
algorithms should probably use the freestanding functions).

A lot of this code will become much easier to use as soon as we can agree to bump PDELab to C++14
because that will allow us to get rid of the horribly complicated return type calculations and the related
SFINAE evaluation order trickery - we’ll just write auto and be done with it.

Steffen

> 
> Christian
> 
> On Wed, Sep 16, 2015 at 11:13:03AM +0200, Steffen Müthing wrote:
>> New commit, appeared at Wed Sep 16 11:13:03 2015 +0200
>> as part of the following ref changes:
>> 
>>    branch refs/heads/master    updated from be7c463 -> 1ed50f5
>> 
>> Browsable version: http://cgit.dune-project.org/repositories/dune-pdelab/commit/?id=1ed50f5adacf34a53b08d24cd6dede5940d8c805
>> 
>> ======================================================================
>> 
>> commit 1ed50f5adacf34a53b08d24cd6dede5940d8c805
>> Author: Steffen Müthing <muething at dune-project.org>
>> Date:   Wed Sep 16 11:10:44 2015 +0200
>> 
>>    [Bugfix] Use freestanding TypeTree::child() when it might get passed an empty TreePath
>> 
>> dune/pdelab/ordering/subordering.hh | 2 +-
>> 1 file changed, 1 insertion(+), 1 deletion(-)
>> 
>> 
>> 
>> diff --git a/dune/pdelab/ordering/subordering.hh b/dune/pdelab/ordering/subordering.hh
>> index eaf4679..54b9401 100644
>> --- a/dune/pdelab/ordering/subordering.hh
>> +++ b/dune/pdelab/ordering/subordering.hh
>> @@ -143,7 +143,7 @@ namespace Dune {
>>           }
>> 
>>         // Call the single-level mapping step of our ancestor ordering.
>> -        baseOrdering().child(tp).map_lfs_indices(begin,end,out);
>> +        TypeTree::child(baseOrdering(),tp).map_lfs_indices(begin,end,out);
>>       }
>> 
>>       // Template recursion for walking up the TreePath to the BaseOrdering
>> 
>> _______________________________________________
>> dune-pdelab-commit mailing list
>> dune-pdelab-commit at dune-project.org
>> http://lists.dune-project.org/mailman/listinfo/dune-pdelab-commit
> 
> --
> Prof. Dr. Christian Engwer
> Institut für Numerische und Angewandte Mathematik
> Fachbereich Mathematik und Informatik der Universität Münster
> Einsteinstrasse 62
> 48149 Münster
> 
> E-Mail  christian.engwer at uni-muenster.de
> Telefon +49 251 83-35067
> FAX     +49 251 83-32729
> 
> _______________________________________________
> dune-pdelab mailing list
> dune-pdelab at dune-project.org
> http://lists.dune-project.org/mailman/listinfo/dune-pdelab
> 

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 455 bytes
Desc: Message signed with OpenPGP using GPGMail
URL: <https://lists.dune-project.org/pipermail/dune-pdelab/attachments/20150916/cd5b9ee7/attachment.sig>


More information about the dune-pdelab mailing list