[PD] msd compile problem

Nicolas Montgermont montgermont at la-kitchen.fr
Wed May 11 17:10:55 CEST 2005


Hi,

There is a difference at instanciation too :

Using a name introduced by a typedef in a friend declaration or in an 
explicit instantiation is now rejected, as specified by the ISO C++ 
standard.

	class A;
	typedef A B;
	class C { 
	  friend class B;      // error, no typedef name here
	  friend B;            // error, friend always needs class/struct/enum
	  friend class A;      // OK
	};
	
	template <int> class Q {};
	typedef Q<0> R;
	template class R;      // error, no typedef name here
	template class Q<0>;   // OK

I think there is an error with the very last lines of the msd.h :

	#define MSD(NAME,CLASS,N) \
	...
	\
	typedef msdN<N> CLASS; \ 
	FLEXT_NEW_V(NAME,CLASS)

try to instantiate in the main.cpp of msd with :

FLEXT_NEW_V("msd",template class msdN<1>)


instead of

MSD("msd",msd,1)

and to remove the FLEXT_NEW_V(NAME,CLASS) from the msd.h

Cheers,

Nicolas




More information about the Pd-list mailing list