Changeset 286 for trunk/openjdk/jdk/src/windows/javavm
- Timestamp:
- Apr 23, 2011, 12:54:45 AM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/openjdk/jdk/src/windows/javavm/export/jni_md.h
r278 r286 41 41 #ifdef __cplusplus 42 42 43 inline void jsafe_cast_POD_type_only(...) {} 44 43 45 /* template for safe type casting: the generic version lets the compiler 44 46 * decide (as if no template was used); specific instantiations deal with 45 * special cases which are guaranteed to be safe */ 47 * special cases which are guaranteed to be safe. Note that it cannot be used 48 * with non-POD types as otherwise it would implicitly call the copy ctor which 49 * may have various unwanted side effects */ 46 50 template<typename TR, typename TS> 47 inline TR jsafe_cast(TS ts) { return ts; }51 inline TR jsafe_cast(TS ts) { jsafe_cast_POD_type_only(ts); return ts; } 48 52 49 53 #ifdef __EMX__
Note:
See TracChangeset
for help on using the changeset viewer.