Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 10559 - GCC 3.X and STD
Summary: GCC 3.X and STD
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: x86 Linux
: High normal (vote)
Assignee: Gentoo Linux bug wranglers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2002-11-10 18:51 UTC by Bernardo S. A. Silva
Modified: 2003-02-04 19:42 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Bernardo S. A. Silva 2002-11-10 18:51:10 UTC
Just answer me. It is an ASCII error of mine or it is a strange incompatibility:

 Try this C++ code:

 #include <vector>
 int main() {
  vector < int > V;
 }

 It works fine on GCC 2.9X but it doesn't work on GCC 3.X:

 # test.c: In function `int main()':
 # test.c:4: `vector' undeclared (first use this function)
 # test.c:4: (Each undeclared identifier is reported only once for each function 
 #   it appears in.)
 # test.c:4: parse error before `>' token
 
 And when we wrote this code:

 #include <vector>
 int main() {
  std::vector < int > V;
 }

 It works on both. But a lot of programs use the first and the "buged" syntax
what does a lot of incompatibilitys on GCC 3.X. Why did it does it and why don't
make STD definitions like on GCC 2.9X ( #define vector std::vector )???

   Just a question, sorry about my ignorance... 

   Thanx... Bernardo
Comment 1 SpanKY gentoo-dev 2002-11-10 20:40:55 UTC
its actually supposed to work the way it does in 3.x  it was just a matter of not being very restrictive in 2.95.x