Boost logo

Proto :

Subject: Re: [proto] Defining the result domain of a proto operator
From: Joel Falcou (joel.falcou_at_[hidden])
Date: 2011-08-26 11:31:09


On 26/08/2011 17:27, Brandon Kohn wrote:
> I solved this kind of problem by tagging the various types in traits
> structs and then embedding these traits in the transforms for the
> various operations.
>
> Here are examples of my expression, grammar, and binary function
> definitions:
>
> https://github.com/brandon-kohn/Geometrix/blob/master/geometrix/algebra/expression.hpp
>
>
> https://github.com/brandon-kohn/Geometrix/blob/master/geometrix/algebra/grammar.hpp
>
>
> https://github.com/brandon-kohn/Geometrix/blob/master/geometrix/algebra/binary_functions.hpp
>
>
> I'm not sure if this is the best way to do these, but it does work.
>

These coudl be grammar. Anytime you want to have somethign selecting
somethign based on expression structure, it is a grammar. Such
metafonction systems ar eusualyl brittle or not extensible enough.


Proto list run by eric at boostpro.com