string - output on cout

Sebastian Setzer
Thu Jan 27 00:43:00 GMT 2000

I wrote a simple program but got a linker - error.
Here's the Code :
#include <string>
#include <iostream.h>

void main(){
  string a("A");
  string b("B");
  string c = a+b;
  cout << c << endl;

And here's the output of g++ :
emplate2b0i0_R7ostreamRCt12basic_string3ZX01ZX11ZX21_R7ostream+0x32) und
efined reference to •stream::write(char const *, int)'
collect2: ld returned 1 exit status

Is it a bug ? Must I link it with a library ? Is my installation wrong ?

I use the Jan 15th - patch on Windows 95 and gcc 2.95.2.

Thanks in advance,
          Sebastian Setzer

Want to unsubscribe from this list?
Send a message to

More information about the Cygwin mailing list