Boost logo

Boost :

From: David Abrahams (dave_at_[hidden])
Date: 2003-10-08 16:35:14

"E. Gladyshev" <egladysh_at_[hidden]> writes:

> --- David Abrahams <dave_at_[hidden]> wrote:
>> > I guess the problem is I can't really think of a situation where it makes
>> > any difference if the variant contains the prepended empty_type or
>> > a type from the original list. I'm guessing you can though, so please
>> > help me understand.
>> Just go back to the original design rationale for variant. If it
>> really doesn't matter, variant should just prepend empty_type
>> internally and always. Then we can stop having this discussion ;-)
> You have my vote on that.
> I am going to be using variant a lot in my library.
> I'd really like to get it right.

Just to be clear, I wasn't seriously suggesting that change. If
that's what you want always, just prepend empty_type yourself; cheap
and easy. It seems to me that Eric's chosen invariant is a useful
one, and I'm not at all convinced that unconditionally preventing
people from having that invariant is more right than the current

Dave Abrahams
Boost Consulting

Boost list run by bdawes at, gregod at, cpdaniel at, john at