Article View: gnu.g++.help
Article #529(none)
From: Brian McGinnis
Date: Mon, 15 Apr 1991 15:36
Date: Mon, 15 Apr 1991 15:36
64 lines
3070 bytes
3070 bytes
Subject: G++ question.
--------
Hi,
I don't know that this is the right place to post this, but it is the
only address I had available. Please forgive me if it is the wrong
place and forward the message or tell me where to send this type of request.
I have been trying to get the NIHCL library to compile with G++ but
keep running into the following errors. This error is repeated over
and over for every class that attempts to compile. I tracked the error
message down to a macro definition wich follows the error listing.
Every time this macro is called the error message is reapeted. I
couldn't make out the error and was hoping that maybe someone with
greater knowledge and experience than myself could. Thankyou immensely in advance.
Brian McGinnis
mcginnis@applga.aa.cad.slb.com
ERROR MESSAGE
-------------------------------
Object.h: In function class Class &static Class::castdown (class Object &):
In file included from Collection.h:75, from ArrayOb.h:72, from ArrayOb.c:85:
Object.h:468: type `Class' is not a base type for type `Object'
ObjectObject.h: In function class Class &static Class::castdown (class Object &):
In file included from Collection.h:75, from ArrayOb.h:72, from ArrayOb.c:85:
Object.h:468: type `Class' is not a base type for type `Object'
Object.h: In function const class Class &static Class::castdown (const class O
bject &):
ERROR CODE
-------------------------------
#ifdef MI
#define DECLARE_CASTDOWN(classname) \
static classname& castdown(Object& p) \
{ return *(classname*)(&p ? p._safe_castdown(*desc()) : 0); }
\
static const classname& castdown(const Object& p) \
{ return *(const classname*)(&p ? p._safe_castdown(*desc()) :
0); } \
static classname* castdown(Object* p) \
{ return (classname*)(p ? p->_safe_castdown(*desc()) : 0); } \
static const classname* castdown(const Object* p) \
{ return (const classname*)(p ? p->_safe_castdown(*desc()) : 0
); } \
#else
#define DECLARE_CASTDOWN(classname) \
static classname& castdown(Object& p) { return (clas
sname&)p; } \
static const classname& castdown(const Object& p) { return (cons
t classname&)p; } \
static classname* castdown(Object* p) { return (clas
sname*)p; } \
static const classname* castdown(const Object* p) { return (cons
t classname*)p; } \
#endif
-----------------------
Technical Details
Message-ID:
<9104151536.AA03587@applga.aa.cad.slb.com>Path:
arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!cis.ohio-state.edu!tut.cis.ohio-state.edu!unreplyable!garbageShow Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!cis.ohio-state.edu!tut.cis.ohio-state.edu!unreplyable!garbage From: applga!mcginnis@SHARKEY.CC.UMICH.EDU (Brian McGinnis) Newsgroups: gnu.g++.help,comp.lang.c++ Subject: (none) Message-ID: <9104151536.AA03587@applga.aa.cad.slb.com> Date: 15 Apr 91 15:36:01 GMT Sender: daemon@tut.cis.ohio-state.edu Followup-To: gnu.g++.help Distribution: world Organization: Gatewayed from the GNU Project mailing list help-g++@prep.ai.mit.edu Lines: 64