Re: GCC BUG?



-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

"stork" <stork@xxxxxxxxxxxx> writes:

I think GCC 4 has trouble with classes derived from template
classes.

I doubt it, considering that huge chunks of the Standard Library
depend upon this facility (e.g. std::basic_ios<>).

The whole system alluded to by below compiles fine with Visual C++
7.

MS VC++ does not have a stellar reputation for standards compliance.
If your code builds, it does not mean is is Standard C++. GCC/g++
will reject your code if it is not valid Standard C++.

Similarly, this ::node_type is a public nested class of
skip_list_type, and once again, GCC can't see it? Ideas for
workarounds or am I just hosed?

http://www.catb.org/~esr/faqs/smart-questions.html

Please read the above. You didn't provide:
- - the compiler errors g++ emitted, so we have no clue what the
problem was.
- - a minimal compilable testcase; the example you posted was
incomplete, so is not any use.

Obvious issues with the code:
- - you don't initialise the members of the instance type with an
initialiser list, but within the constructor body.
- - you don't chain up to the parent constructor.
- - you are using private inheritance; was this what you really wanted?


Regards,
Roger

- --
Roger Leigh
Printing on GNU/Linux? http://gutenprint.sourceforge.net/
Debian GNU/Linux http://www.debian.org/
GPG Public Key: 0x25BFB848. Please sign and encrypt your mail.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2 (GNU/Linux)
Comment: Processed by Mailcrypt 3.5.8+ <http://mailcrypt.sourceforge.net/>

iD8DBQFEDY3xVcFcaSW/uEgRAsnkAKDFgAjIXTjHK1iDQJwe8YywGCSg6ACeMK5O
U15af7ho1YRiBAMOr7G8NbI=
=HWnH
-----END PGP SIGNATURE-----
.



Relevant Pages