Boost logo

Boost Users :

Subject: Re: [Boost-users] [Tuple] What's the point?
From: Zachary Turner (divisortheory_at_[hidden])
Date: 2009-07-10 10:08:24


This may cause some disagreements but I'm honestly not sure that I
agree with the idea that tuples should behave like sequences. Most
other languages that enable functional programming style explicitly
disallow this, and for good reason. It leads to bad programming
style, and makes it all too easy and comfortable to make an arbitrary
sized tuple, when usually a tuple of larger than a few elements
indicates a programming design problem. I also kind of agree with the
philosophy that "sequence" should imply "collection of homogeneous
types", which viewing a tuple as a sequence violates. In other
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.


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