delorie.com/archives/browse.cgi | search |
X-Authentication-Warning: | delorie.com: mailnull set sender to djgpp-bounces using -f |
Date: | Mon, 25 Feb 2002 18:29:36 +0100 |
Message-Id: | <200202251729.SAA23832@acp3bf.physik.rwth-aachen.de> |
From: | Hans-Bernhard Broeker <broeker AT physik DOT rwth-aachen DOT de> |
To: | djgpp AT delorie DOT com |
Subject: | Re: STL-vector suddenly doesn't work |
X-Newsgroups: | comp.os.msdos.djgpp |
In-Reply-To: | <20020225164625.3900.qmail@web20808.mail.yahoo.com> |
Reply-To: | djgpp AT delorie DOT com |
Errors-To: | nobody AT delorie DOT com |
X-Mailing-List: | djgpp AT delorie DOT com |
X-Unsubscribes-To: | listserv AT delorie DOT com |
In article <20020225164625 DOT 3900 DOT qmail AT web20808 DOT mail DOT yahoo DOT com> you wrote: > I had a symilar problem and using the older > header <vector.h> instead of '<vector>' worked. That's only a temporary solution, though. The "new" way is to #include <vector>, and access the classes via their proper 'namespace'. Namespaces are one of the few new features of ANSI C++ that were not yet (properly) implemented in GCC before version 3.0. Now they are, and your sources will have to use them. I.e. instead of #include <vector.h> vector<int> myVector; you're now supposed to code #include <vector> std::vector<int> myVector; or #include <vector> using namespace std; vector<int> myVector; > I didn't expect documentation about STL in gcc info docs! I didn't refer to the STL docs. But rather to the DJGPP-specific READMEs that came with your GCC 3.0.* zipfiles. Or to the general GCC docs and "whatsnew" notes, for that matter. -- Hans-Bernhard Broeker (broeker AT physik DOT rwth-aachen DOT de) Even if all the snow were burnt, ashes would remain.
webmaster | delorie software privacy |
Copyright � 2019 by DJ Delorie | Updated Jul 2019 |