Boost logo

Boost :

Subject: Re: [boost] [optional] little addition... optional_assign_to, optional_move_to, optional_swap?
From: Niels Dekker - mail address until 2010-10-10 (niels_address_until_2010-10-10_at_[hidden])
Date: 2009-03-06 16:21:54


Fernando Cacciola wrote:
> Hi Arno,
  ...
> Thus, until move semantics are practically usable (whether via
> Boost.Move or C++0x) I would either add the three functions as member
> functions, or just your optional_assign() as a free function, but not
> two members and one free standing.
>
> What do you think?

FWIW, my vote would go to your first option, adding
optional_assign_to(T&), optional_move_to(T&), and optional_swap(T&) as
member functions to optional<T>. But of course, my name isn't Arno!

Kind regards, Niels


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