"Fernando Cacciola \(Home\)" <[EMAIL PROTECTED]> writes:

> optional<Window> opt( in_place<Window>(point(0,0),point(10,10)));
>
> here, in_place() is used to forward T's ctor argument to optional<> so that
> T is effectively constructed in-place right within the aligned storage.
>
> Is this what you want?

I have to say that I like the idea of using placement-new with an
optional<> argument better, since it doesn't get you involved with
the const ref/non-const ref/rvalue forwarding problem.

-- 
Dave Abrahams
Boost Consulting
www.boost-consulting.com

_______________________________________________
Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost

Reply via email to