From: "Peter Lewerin" Newsgroups: comp.os.msdos.djgpp Subject: Re: Problem with the string data format! Date: 19 May 1997 18:19:28 GMT Organization: - Lines: 30 Message-ID: <01bc6481$445c7500$6847f482@peterlew> References: <01bc643c$9a240b00$d541b7c2 AT engineering5 DOT engineering DOT it> <33806a96 DOT 5931584 AT ursa DOT smsu DOT edu> NNTP-Posting-Host: dialup71-5-4.swipnet.se NNTP-Posting-User: s-36170 To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Precedence: bulk Tony O'Bryan skrev i inlägg <33806a96 DOT 5931584 AT ursa DOT smsu DOT edu>... > On 19 May 1997 10:01:51 GMT, "Lorenzo Soncini" wrote: > > > How can I use the string data type with DJGpp ? > > there is no string data type per se in DJGPP (or C for that matter). True, but there *is* a string class in (the working paper for) C++, and it's implemented in the C++lib for DJGPP. It's declared in the header std/string.h, which in turn uses the declaration for basic_string from std/bastring.h. I suppose you would use it like this: #include #include int main() { string s("Hello world!"); cout << s << endl; return 0; } (On my system, this works when compiled with gxx, but not when compiled with RHIDE (no errors even with RHIDE, though).)