This is the mail archive of the libstdc++@gcc.gnu.org mailing list for the libstdc++ project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Template instantiation results in a link failure


After updating to gcc 4.6.0, the following code fails to link:

#include <algorithm>
#include <iterator>
#include <iostream>

int main()
{
	std::find(std::istreambuf_iterator<char>(std::cin),
		  std::istreambuf_iterator<char>(), '\n');
	return 0;
}

The link failure is:
t.C:
(largish mangle): undefined reference to `std::basic_streambuf<char, std::char_traits<char> >::__safe_gbump(long)'


I see the innards that are responsible for this error, what I can't see is what I'm doing wrong here.


Attachment: pgp00000.pgp
Description: PGP signature


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]