This is the mail archive of the
libstdc++@gcc.gnu.org
mailing list for the libstdc++ project.
Re: swap does not compile
On Mon, Jan 12, 2004 at 10:44:44AM +0100, Lars Gullik Bjønnes wrote:
> #include <vector>
> #include <algorithm>
>
> using std::swap;
>
> int main()
> {
> size_t a = 1;
> size_t b = 2;
> swap(a, b);
> }
> swap.C: In function `int main()':
> swap.C:10: error: no matching function for call to `swap(size_t&, size_t&)'
For the record I see this too, with today's build, on i386-unknown-freebsd4.8,
and as reported it works if <vector> isn't included.
Is this more fallout from the strong-using work?
jon
--
"Political satire became obsolete when Henry Kissinger was awarded the
Nobel Prize."
- Tom Lehrer