src/share/vm/utilities/globalDefinitions_visCPP.hpp

changeset 7001
b6a8cc1e0d92
parent 6198
55fb97c4c58d
child 7535
7ae4e26cb1e0
child 9478
f3108e56b502
equal deleted inserted replaced
7000:631c3a4ea10c 7001:b6a8cc1e0d92
114 typedef unsigned char jubyte; 114 typedef unsigned char jubyte;
115 typedef unsigned short jushort; 115 typedef unsigned short jushort;
116 typedef unsigned int juint; 116 typedef unsigned int juint;
117 typedef unsigned __int64 julong; 117 typedef unsigned __int64 julong;
118 118
119 //----------------------------------------------------------------------------------------------------
120 // Special (possibly not-portable) casts
121 // Cast floats into same-size integers and vice-versa w/o changing bit-pattern
122
123 inline jint jint_cast (jfloat x) { return *(jint* )&x; }
124 inline jlong jlong_cast (jdouble x) { return *(jlong* )&x; }
125
126 inline jfloat jfloat_cast (jint x) { return *(jfloat* )&x; }
127 inline jdouble jdouble_cast(jlong x) { return *(jdouble*)&x; }
128
129 119
130 //---------------------------------------------------------------------------------------------------- 120 //----------------------------------------------------------------------------------------------------
131 // Non-standard stdlib-like stuff: 121 // Non-standard stdlib-like stuff:
132 inline int strcasecmp(const char *s1, const char *s2) { return _stricmp(s1,s2); } 122 inline int strcasecmp(const char *s1, const char *s2) { return _stricmp(s1,s2); }
133 inline int strncasecmp(const char *s1, const char *s2, size_t n) { 123 inline int strncasecmp(const char *s1, const char *s2, size_t n) {

mercurial