Boost logo

Boost :

From: Gennadiy Rozental (gennadiy.rozental_at_[hidden])
Date: 2005-03-08 14:11:27


> Agreed. I was going to say that an empty optional should print
> something, but couldn't articulate the reasons. Thanks.

Printing something only for empty optional may lead to unclear output. For
example what should be an output of:

optional<string> v = "empty";
optional<string> v;

optional<bool> v = false;
optional<bool> v;

optional<int> v = 0;
optional<int> v;

Gennadiy


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk