Avoid an invalid GCC warning by using a union.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34159 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Stephan Aßmus 2009-11-20 16:37:47 +00:00
parent 5cea99288b
commit d2b45aa3de
1 changed files with 6 additions and 4 deletions

View File

@ -196,10 +196,12 @@ NaturalCompare(const char *s1, const char *s2)
{
struct Chunk {
int32 type;
char* ascii;
// Type = 0
int32 num;
// Type = 1
union {
char* ascii;
// Type = 0
int32 num;
// Type = 1
};
};
Chunk a;