Syntax question
Syntax question
- Subject: Syntax question
- From: Hisaoki Nishida <email@hidden>
- Date: Sat, 25 May 2002 03:10:34 -0400
Would this code work as expected?
[tileInfoList objectAtIndex:tileNum]->rcSrc->origin->x = tRect.origin.x;
tileInfoList is a NSMutableArray.
tileNum is an int.
rcSrc is NSRect.
tRect is also NSRect.
You can assume that the object pointed to by tileNum is a struct
containing rcSrc.
But I'm not sure if it will be recognized as a struct, and instead an id?
If so, what should I do?
What I expect to be done is substitute the x value in tRect.origin to
the NSRect.origin.x struct element in the tileInfoList array.
[tileInfoList objectAtIndex:tileNum] returns the struct by reference (?)
so I thought that '->' would work here. Unless I have to typecast the
struct or something?
Thanks!
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.