swarm-support
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Swarm-Support] update target in FCall during make


From: Scott Christley
Subject: Re: [Swarm-Support] update target in FCall during make
Date: Fri, 28 Jul 2006 14:19:05 -0400

Ken,

The GCC version you are using is being more strict about the declaration matching the definition.  What you can do is update the code in FCall.h to use the id data type:

void updateTarget (id s, id target);

Then change the code in FCall.m and perform a cast, like this:

void
updateTarget (id s, id target)
{
  FCall_c *self = (FCall_c *)s;


Alternatively, maybe you can move the declaration in FCall.h to be at the end of the file, after @interface FCall_c ... @end.  I thought maybe I tried this and it created an error elsewhere.

The second error you got after making the change is because GCC does not know about the FCall_c class, because FCall_c is defined just below that declaration in the file.

cheers
Scott

On Jul 28, 2006, at 1:44 PM, Kenichi W Okamoto wrote:

Hello there,

Does anybody know why the updatetarget function declaration in FCall.h and defobj.h has different arguments from the updatetarget in FCall.m (updatetarget(id call, id target) v.s. updatetarget(FCall_c *self, id target) ) on Swarm2.2?

When running make I keep getting told there's a problem with conflicting types:

FCall.m: At top level:
FCall.m:592: error: conflicting types for 'updateTarget'
../defobj/FCall.h:43: error: previous declaration of 'updateTarget' was here
make[5]: *** [FCall.lo] Error 1

Tried modifying FCall.h and defobj.h so that lines 43 and 1170, respectively, read:

extern void updateTarget (FCall_c *self, id target);

to be consistent with FCall.m.

Whereupon:

./../defobj/defobj.h:1170: error: expected ')' before '*' token

Does anybody know how to get around this? I'm on RH9 Linux and am using gcc-4.1.1...

Thanks in advance,
Ken

+++++++++++++++++++
K W Okamoto
Dept. Ecology & Evolutionary Biol.
UCLA
Los Angeles, CA 90025 USA
(310) 206-1464
_______________________________________________
Support mailing list


reply via email to

[Prev in Thread] Current Thread [Next in Thread]