Boost logo

Boost :

From: Thorsten Ottosen (nesotto_at_[hidden])
Date: 2004-08-13 11:26:34


"Daniel Frey" <daniel.frey_at_[hidden]> wrote in message news:cfhteq$piv$1_at_sea.gmane.org...

|Hm, good point. The only "solution" I could come up with is shown below,
|but I don't know how portable/robust it is.

|
| template< typename T >
| internal f( const T& x )
| {
| if( sizeof( f(x),internal() ) == sizeof( char ) ) {
| // Non-ADL-implementation
| std::cout << 1 << std::endl;
| }
| else {
| // ADL-forwarder
| f( x );
| }
| return internal();
| }

why do you return an internal here? I mean, weed want to return f(x).

br

Thorsten


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