From 6b4308e8b3dc41d588ff9e7519da813705a3cd94 Mon Sep 17 00:00:00 2001 From: Kenneth Russel Date: Mon, 2 Jan 2006 22:41:10 +0000 Subject: Fixed build problem with recent 64-bit changes. Now force enum types to be int instead of long. Neither is really correct but int is probably more correct and its behavior is easier to explain than long. git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/trunk@508 232f8b59-042b-4e1e-8c03-345bb8c30851 --- src/classes/com/sun/gluegen/cgram/HeaderParser.g | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/classes/com/sun/gluegen/cgram/HeaderParser.g b/src/classes/com/sun/gluegen/cgram/HeaderParser.g index 78ba5c54a..a9da6635c 100644 --- a/src/classes/com/sun/gluegen/cgram/HeaderParser.g +++ b/src/classes/com/sun/gluegen/cgram/HeaderParser.g @@ -289,7 +289,12 @@ options { } if (enumType == null) { - enumType = new EnumType(enumTypeName, SizeThunk.LONG); + // This isn't quite correct. In theory the enum should expand to + // the size of the largest element, so if there were a long long + // entry the enum should expand to e.g. int64. However, using + // "long" here (which is what used to be the case) was + // definitely incorrect and caused problems. + enumType = new EnumType(enumTypeName, SizeThunk.INT); } return enumType; -- cgit v1.2.3