Boost logo

Boost :

From: Thorsten Ottosen (nesotto_at_[hidden])
Date: 2004-04-13 06:51:07

"Vladimir Prus" <ghost_at_[hidden]> wrote in message

>I wish we can get away from BOOST_LVALUE too. The simple approach of:
> template<class T>
> void sort(T t) {}
> template<class T>
> void sort(T& t) {}
>does not really work, since there's ambiguity when passing non-const

One is a language change like &&. If we had

 template<class T>
 void sort(T t) {}

 template<class T>
 void sort(T& t) {}

template< class T >
void sort( const T& t )

wouldn't it be possible to enable/disable certain combination in certain
situaltions, so it
would just work ? Anyway, my brain has stopped thinking, so I'll better do
some homework.



Boost list run by bdawes at, gregod at, cpdaniel at, john at