From: khan AT xraylith DOT wisc DOT edu (Mumit Khan) Subject: Re: Templates 14 Oct 1998 10:02:32 -0700 Message-ID: <199810131438.JAA23800.cygnus.gnu-win32@venus.xraylith.wisc.edu> References: To: rayers AT TTACS DOT TTU DOT EDU Cc: gnu-win32 AT cygnus DOT com rayers AT ttacs DOT ttu DOT edu writes: > I was wondering if cygwin32 b19 works with templates. I made a real easy > template class for a list, which compiles fine on MSVC++, but throws a > bunch of errors when I try with cygnwin32. Below are the errors that it > pops out. > > In file influded from test4.cpp:10: > listarr.cpp:13: syntax error before '<' > test4.cpp: In function 'int main(...)': > test4.cpp:144: confused by earlier errors, bailing out > > That is it. The last error occurs on the last brace of the program. > Below is snippet from the two files: listarr.cpp test4.cpp > > listarr.cpp > ----------- [ ... ] > template > List() << Line 13 > { > delete [] element; > } Please look at line 13 again. If MSVC compiles this, it should be able to drive your car and mow your lawn as well ;-) May I suggest you make use of a more appropriate forum such comp.lang.c++ for questions on programming in C++? You should definitely upgrade your C++ compiler to egcs if you haven't done so already (see Cygnus home page for a pointer to my site) if you're planning on doing any C++ programming on cygwin32. Regards, Mumit - For help on using this list (especially unsubscribing), send a message to "gnu-win32-request AT cygnus DOT com" with one line of text: "help".