Re: Multidimensional C arrays as OBJ-C method args: partial
Re: Multidimensional C arrays as OBJ-C method args: partial
- Subject: Re: Multidimensional C arrays as OBJ-C method args: partial
- From: "Erik M. Buck" <email@hidden>
- Date: Wed, 2 Jan 2002 19:26:35 -0600
- Organization: EMB & Assocites Inc.
>
-(void)setFloatValueByTotalingArrayPointer:(float *)theArray[];
Try -(void)setFloatValueByTotalingArrayPointer:(float *[])theArray;
or
typedef float *myArray_t[6];
-(void)setFloatValueByTotalingArrayPointer:(myArray_t)theArray;
or
-(void)setFloatValueByTotalingArrayPointer:(float [6][3])theArray;
or
typedef float *myArray_t[6][3];
-(void)setFloatValueByTotalingArrayPointer:(myArray_t)theArray;
I have not tried these myself yet, but I think they may work. I have not
tried these things in Objective-C for a while...
Any type that is expressible in C can be used as the type of an Objective-C
method argument. Just fiddle for the correct syntax. A quick look at the
grammar for Objective-C would probably clarify the issue.