Boost logo

Boost :

From: Peter Dimov (pdimov_at_[hidden])
Date: 2002-11-22 06:48:01


From: "David Abrahams" <dave_at_[hidden]>
>
> Here's what I think might be a correct implementation:
>
> template <class T, class U> T implicit_cast(U const& x) { return x; }
> template <class T, class U> T implicit_cast(U& x) { return x; }

The correct implementation IIRC is

template<class T> T implicit_cast(typename identity<T>::type x) { return
x; }


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