This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
Re: template under gcc version 3.3.2
- From: corey taylor <corey dot taylor at gmail dot com>
- To: "Morten.Gulbrandsen" <f1000mhz at yahoo dot de>, gcc-help at gcc dot gnu dot org
- Date: Sat, 29 Jan 2005 14:59:08 -0600
- Subject: Re: template under gcc version 3.3.2
- References: <41FB92D1.8060802@yahoo.de>
- Reply-to: corey taylor <corey dot taylor at gmail dot com>
Morten,
First one note, I don't see you including anything for the std::deque type.
You should at least add: #include <deque>
corey
> g++ -ansi -pedantic -Wall -o stest5_test_00.out stest5_test_00.cpp -L
> /opt/sfw/gcc-3/lib/ -R /opt/sfw/gcc-3/lib/ -lstdc++
> stest5_test_00.cpp:11: error: syntax error before `;' token
>
> #include <iostream>
> #include <string>
> #include <cstdlib>
>
> // #include "stack5.hpp"
>
> template <typename T>
> class Stack {
> private:
> std::deque<T> elems; // elements