delorie.com/archives/browse.cgi | search |
From: | Roman Scherzer <scherzer AT cs DOT bonn DOT edu> |
Newsgroups: | comp.os.msdos.djgpp |
Subject: | What about ISO/ANSI C++ |
Date: | Mon, 16 Mar 1998 14:48:35 +0100 |
Organization: | RHRZ - University of Bonn (Germany) |
Lines: | 48 |
Message-ID: | <350D2DB3.1686@cs.bonn.edu> |
NNTP-Posting-Host: | zeus.informatik.uni-bonn.de |
Mime-Version: | 1.0 |
Xcanpos: | shelf.01/199803301801!0033752209 |
To: | djgpp AT delorie DOT com |
DJ-Gateway: | from newsgroup comp.os.msdos.djgpp |
Currently I'm reading the fantastic C++ book by Bjarne Stroustrup and I'm wondering why gcc does not recognize several STL calls. I'm using gcc, gpp with lgp (all versions == 2.8.0). When I try to write a simple program like: //--------------------------------------------------- #include <iostream> #include <string> int main() { std::string Test; // an empty string std::cout << Test; // display an empty string ;) return 0; } //--------------------------------------------------- Compile options: -Wall -s -O3 I get some nerving warnings like: ...redefining NULL Macro in include files... If I add some functions like: Test.compare() or Test.find() (of course with right parameters) I get errors because gcc doesn't know functions like compare or find. So what ? Isn't string::find() an ISO/ANSI Standard Template Function ? In Bjarne's book find() and compare() are (!) STL functions. So please help me ! -- Roman Scherzer E-mail : scherzer AT cs DOT bonn DOT edu Homepage: http://titan.cs.bonn.edu/~scherzer/
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |