[comp.lang.c++] TC++ bug?

pete@edsr.eds.com (Pete Humphrey) (08/01/90)

I recently tried to compile some of my code (which uses generic.h) with TC++.
I was unable to get the code to compile, and I suspect a bug in the compiler.
The following code segment (taken pretty much right out of Stroustrup)
generates a compile error in Turbo C++.  It works fine in GNU C++ and 
Zortech C++.  Is there a bug in the Turbo C++ implementation of generic.h?

----------- example -------------
#include <stdio.h>

#ifndef GENERICH
#include <generic.h>
#endif

#define gslist(type) name2(type,gslist)
#define gslist_iterator(type) name2(type,gslist_iterator)

#define gslistdeclare(type)				\
struct gslist(type)					\
{							\
	type insert(type a) { return a; }		\
	type append(type a) { return a; }		\
} ;

declare(gslist,int);

gslist(int) list;





--
				
Pete Humphrey			US Mail:
pete@edsr.eds.com		EDS Research
(505) 345-1863			5951 Jefferson Street N.E.
				Albuquerque, New Mexico 87109-3432