$include_dir="/home/hyper-archives/boost/include"; include("$include_dir/msg-header.inc") ?>
From: Jonathan Turkanis (technews_at_[hidden])
Date: 2005-07-09 22:05:15
Jost, Andrew wrote:
> This is my first post to the Boost distribution list, so please feel
> free to speak up if you find any part of this message to be outside
> the normal decorum.
>
> I am curious if there is support for what I'm calling a "dual_state"
> template class. Anyone familiar with Perl will instantly recognize
> the parallel. The idea is to attach a "statedness" value to arbitrary
> objects, allowing us to consider them defined or undefined. Newly
> constructed dual_state objects are undefined. For example,
It sounds like the functionality you want is provided by Boost.Optional:
http://www.boost.org/libs/optional/doc/optional.html
(And yes, it is extremely useful ;-) )
Jonathan