|
Boost Users : |
Subject: Re: [Boost-users] [Tuple] What's the point?
From: Joel de Guzman (joel_at_[hidden])
Date: 2009-07-10 20:18:23
Zachary Turner wrote:
>> On Fri, Jul 10, 2009 at 11:26 AM, Joel de Guzman<joel_at_[hidden]> wrote:
>>> functional languages if you need to manually operate on each element
>>> of a tuple other methods are provided like matching. I actually think
>>> that it might be possible to achieve some matching like constructs in
>>> C++, but I don't think (?) much if any research has been devoted to
>>> that.
>> Erm... every sentence above begs the question: why?
>
> ? I'm not sure what you mean by this sentence begging the question of
> why. If you know of any research that has been done regarding match
> constructs in C++ then please refer me to it. But the reason I don't
> think much has been done is because I've never heard of any. OTOH I
> don't claim to be aware of everything going on in the C++ world, so
> I'd be interested to read any such research you know of.
For this case, we are actually in agreement. And, actually, I am
investigating pattern matching (like in FP) for Fusion. Yes, in
many cases, this is very powerful. I can agree with you that simple
iteration is too low level. But Fusion is not limited to plain
for_each iteration. The power is in the composition of the algorithms
to do more complex functionalities, like pattern matching, complex
traversals, etc.
Regards,
-- Joel de Guzman http://www.boostpro.com http://spirit.sf.net
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net