Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ Library support » U++ Core » PolyDeepCopyNew: MSC / GCC differ in behaviour
Re: PolyDeepCopyNew: MSC / GCC differ in behaviour [message #29398 is a reply to message #29397] Mon, 18 October 2010 16:16 Go to previous messageGo to previous message
kohait00 is currently offline  kohait00
Messages: 939
Registered: July 2009
Location: Germany
Experienced Contributor
i've got some polymorphic object instantiation factories in development. that's why the need. nevermind. thanks for your patience. basicly, the example provided is an extract of the current work reduced to the 'most simple' to reproduce the compile error.

nevertheless i found the thing to compile under GCC as well, moving the PolyDeepCopyNew<CopyableC<> > to the CopyableC itself, instead of specifying it somewhere in upper hierarchy. but it's actually not what i wanted.. maybe you will have a hint. if not i dont mind.

template<class C, class B = EmptyClass>
class CopyableC : public PolyDeepCopyNew<CopyableC<C,B>, Copyable<CopyableC<C,B>, B> >
{
public:
	virtual const C& GetC() const              = 0;
	virtual C& GetC()                          = 0;
	
	operator const C&() const                  { return GetC(); }
	operator C&()                              { return GetC(); }
};

template<class B, class C, class CB = EmptyClass>
class PolyCopyableC : public B, public CopyableC<C, CB>
{
public:
	virtual const C& GetC() const              { return *this; }
	virtual C& GetC()                          { return *this; }
};

 
Read Message icon4.gif
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: PROPOSAL: SerializeStore helper
Next Topic: Value: no deep copy support?
Goto Forum:
  


Current Time: Sun Aug 24 20:20:59 CEST 2025

Total time taken to generate the page: 0.11463 seconds