home *** CD-ROM | disk | FTP | other *** search
/ Geek Gadgets 1 / ADE-1.bin / ade-dist / kaffe-0.5p4-bin.lha / include / kaffe / jtypes.h next >
C/C++ Source or Header  |  1996-10-12  |  1KB  |  58 lines

  1. /* lib/support/jtypes.h.  Generated automatically by configure.  */
  2. /*
  3.  * jtypes.h
  4.  * Java types.
  5.  *
  6.  * Copyright (c) 1996 Systems Architecture Research Centre,
  7.  *           City University, London, UK.
  8.  *
  9.  * See the file "license.terms" for information on usage and redistribution
  10.  * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  11.  *
  12.  * Written by Tim Wilkinson <tim@sarc.city.ac.uk>, June 1996.
  13.  */
  14.  
  15. #ifndef __jtypes_h
  16. #define __jtypes_h
  17.  
  18. #define    SIZEOF_INT 4
  19. #define    SIZEOF_LONG 4
  20. #define    SIZEOF_LONG_LONG 8
  21. #define    SIZEOF___INT64 0
  22.  
  23. typedef float        jfloat;
  24. typedef double        jdouble;
  25. typedef    void*        jref;
  26. typedef unsigned char    jchar;
  27. typedef char        jbyte;
  28. typedef short         jshort;
  29.  
  30. #if SIZEOF_INT == 4
  31. typedef int        jint;
  32. #elif SIZEOF_LONG == 4
  33. typedef long        jint;
  34. #else
  35. #error "sizeof(int) or sizeof(long) must be 4"
  36. #endif
  37.  
  38. #if SIZEOF_LONG_LONG == 8
  39.  
  40. #define HAVE_NATIVE_INT64
  41. typedef long long    jlong;
  42. #define    JLONG_ZERO    ((jlong)0)
  43.  
  44. #elif SIZEOF___INT64 == 8
  45.  
  46. #define HAVE_NATIVE_INT64
  47. typedef __int64        jlong;
  48. #define    JLONG_ZERO    ((jlong)0)
  49.  
  50. #else
  51.  
  52. typedef struct { jint jl, jh; } jlong;
  53. #define    JLONG_ZERO    { 0, 0 }
  54.  
  55. #endif
  56.  
  57. #endif
  58.