This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

improve type safety wrt unsignedness for java


Java fails to be as portable as it should be in that it relies on an overly lax compiler, this fixes it up. The changes come in two flavors, the cast version, which is very safe, and the change the data from unsigned to signed, or from signed to unsigned, which is slightly more risky. I've chosen the first method for more instances, except where it was exceedingly simple and obvious.

Note, in theory there can be other bits of the java compiler that are compiled on other platforms that are not safe that will need fixing post my other checkin. If anyone spots such a flaw, I'd be happy to fix it, just let me know.

Ok?

reg tested on powerpc-apple-darwin7.4.0.

Attachment: java-un.diff.txt
Description: Text document


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]