[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Maximum alignment question
- From: Bogdan Marinescu <bogdan.marinescu@...>
- Date: Fri, 13 Feb 2009 20:44:16 +0200
Hi,
In lobject.h, the first member of TString (dummy) is used to force
maximum alignment:
/*
** String headers for string table
*/
typedef union TString {
L_Umaxalign dummy; /* ensures maximum alignment for strings */
struct {
CommonHeader;
lu_byte reserved;
unsigned int hash;
size_t len;
} tsv;
} TString;
My question is, why is this necessary? I looked through the code, but
couldn't figure this out.
Best,
Bogdan