#include <intfloat.h>
This structure is used to map an integer and a floating point value to the same memory location. A stucture is used since gcc outputs a warning if you do something like *((Int32*)&myFloat32Value).
公共成员函数 |
|
IntFloat32 ()=default | |
IntFloat32 ( Int32 a) | |
IntFloat32 ( UInt32 a) | |
IntFloat32 ( Float32 a) | |
const IntFloat32 & | operator= (const IntFloat32 &other) |
UInt32 | GetUInt () const |
Public Attributes |
|
union { | |
Int32 i | |
Float32 f | |
}; |
Friends |
|
Bool | operator== (const IntFloat32 &a, const IntFloat32 &b) |
Bool | operator!= (const IntFloat32 &a, const IntFloat32 &b) |
|
default |
|
explicit |
|
explicit |
|
explicit |
const IntFloat32 & operator= | ( | const IntFloat32 & | other | ) |
UInt32 GetUInt | ( | ) | const |
|
friend |
|
friend |
Int32 i |
Float32 f |
union { ... } |