Boost logo

Boost :

Subject: Re: [boost] [utility/value_init] boost::value_initialized<T> direct-initialized?
From: Steven Watanabe (watanabesj_at_[hidden])
Date: 2010-04-01 14:17:23


AMDG

Niels Dekker - address until 2010-10-10 wrote:
> Honestly the MSVC bug just made me more aware that copy-constructors
> and non-copy-constructors can get confused, in a generic context. But
> the example I added to the ticket (#3472) would also be ambiguous on
> other compilers, when value_initialized(T const&) would be added:
>
> class my_integer
> {
> value_initialized<int> m_data;
> public:
> operator value_initialized<int>() const;
> operator int() const;
> };
>
> int main()
> {
> my_integer my;
> value_initialized<int> val(my);
> }
>
> See http://codepad.org/zukxSDbB

Um. Why do you /want/ to do this?

In Christ,
Steven Watanabe


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