Etienne Gagnon writes:
 > Etienne Gagnon wrote:
 > > FYI: The JNI specification guarantees that jbyte is an 8-bit signed value.
 > 
 > Hmmm...  Thinking about all this mess of "non-specified" C byte length...
 > 
 > Can JNI actually be implemented on a 16-bit per byte system?
 > Anybody has a reasonable answer?
 > 
 > To consider:
 >        5.2.4.2.1  Sizes of integer types <limits.h>
 > 
 >         [#1]  The  values  given below shall be replaced by constant
 >         expressions  suitable   for   use   in   #if   preprocessing
 >         directives...
 > ...
 >           -- number  of  bits for smallest object that is not a bit-
 >              field (byte)
 >              CHAR_BIT                         8
 > ...
 > 
 > So, what how would one define "jbyte" on a platform where CHAR_BIT is
 > defined as 16?  JNI depends on having such a type.

You'd have to do something non-ANS.  I suspect that compilers on
machines with non 8-bit bytes would define a byte type as an ANS
extension.

Andrew.


_______________________________________________
Classpath mailing list
[EMAIL PROTECTED]
http://mail.gnu.org/mailman/listinfo/classpath

Reply via email to