Boost logo

Boost :

From: Jeremy Siek (jsiek_at_[hidden])
Date: 2001-01-24 23:38:55

Sorry, I was refering to the case when there are no overloads for
the type in question, and the templated std::swap() is the one
that *should* be used. In this case, if you don't qualify swap()
then you have a problem.

And of course, everyone will say I need to do
"using std::swap" before calling swap. What a pain!
I'm going to liter every single generic function I write
with lots of "using" statements that may or may not work
properly on various compilers. Yuk. There is a better way...

On 25 Jan 2001, Gabriel Dos Reis wrote:

Gabrie> Jeremy Siek <jsiek_at_[hidden]> writes:
Gabrie> [...]
Gabrie> | Also, what about std::swap? You can't use Koenig lookup on that function
Gabrie> | anyways,
Gabrie> Not true. Overloading resolution prefers non-template functions. See
Gabrie> the chapter on `best viable function'.
Gabrie> - Gaby

 Jeremy Siek www:
 Ph.D. Candidate email: jsiek_at_[hidden]
 Univ. of Notre Dame work phone: (219) 631-3906

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