byte alignment
byte alignment
- Subject: byte alignment
- From: Markian Hlynka <email@hidden>
- Date: Tue, 29 Jun 2004 16:23:11 -0600
I'm pretty sure that at some point I had code like this:
typedef struct
{
unsigned char sr : 3; //sourcerow
unsigned char sc : 3; //sourcecol
unsigned char dr : 3; //destrow
unsigned char dc : 3; //destcol
unsigned char capture : 3; //capture flag; 0 for regular, 1 for
capture.
} Ply_T;
but for some reason, sizeof(Ply_T) is returning 3. I think it should be
2. My only explanation is byte alignments. Where in xcode can I change
the complier setting to turn OFF byte alignment? This will cause me
some extremely undesirable behaviour!
Thanks,
Markian
_______________________________________________
xcode-users mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/xcode-users
Do not post admin requests to the list. They will be ignored.