This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
RE: [Fwd: Issue with STL, queues and Stacks]
- From: "Rupert Wood" <me at rupey dot net>
- To: "'Frank'" <fgeck at optonline dot net>
- Cc: <gcc-help at gcc dot gnu dot org>
- Date: Thu, 16 Jan 2003 13:16:40 -0000
- Subject: RE: [Fwd: Issue with STL, queues and Stacks]
Frank wrote:
> I have a program working jut fine under Solaris compiled with Sun
> Workshop compiler, but will not compile with g++. Line it's
> complaining about is :
>
> queue<myclass> *ptr;
>
> or
>
> std::stack<myclass> *ptr;
>
> I have using namespace std: in the .h and it still compains with or
> with out the std:: I have gcc 2.95.3
>
> No thoughts on this?
Works fine here:
fox:~$ cat qs.cpp
#include <queue>
#include <stack>
class myclass { myclass() {}; };
std::stack<myclass> *ptr1;
std::queue<myclass> *ptr2;
fox:~$ local/gcc295/bin/g++ -c -Wall qs.cpp
fox:~$ local/gcc32/bin/g++ -c -Wall qs.cpp
fox:~$ CC -c qs.cpp
fox:~$ CC -V
CC: Sun WorkShop 6 update 2 C++ 5.3 Patch 111685-04 2001/12/13
fox:~$
What's the exact error message?
Rup.