mirror of https://github.com/libsdl-org/SDL.git
Disable warning C4214: nonstandard extension used: bit field types other than int
This shows up with Visual Studio 2019 and is a non-standard extension that we rely on in this code.
This commit is contained in:
parent
faeb2b1f22
commit
4ec5aef028
|
|
@ -294,6 +294,11 @@ typedef union
|
|||
} x;
|
||||
} FP32;
|
||||
|
||||
#ifdef _MSC_VER
|
||||
#pragma warning(push)
|
||||
#pragma warning(disable:4214)
|
||||
#endif
|
||||
|
||||
typedef union
|
||||
{
|
||||
Uint16 u;
|
||||
|
|
@ -305,6 +310,10 @@ typedef union
|
|||
} x;
|
||||
} FP16;
|
||||
|
||||
#ifdef _MSC_VER
|
||||
#pragma warning(pop)
|
||||
#endif
|
||||
|
||||
static float half_to_float(Uint16 unValue)
|
||||
{
|
||||
static const FP32 magic = { (254 - 15) << 23 };
|
||||
|
|
|
|||
Loading…
Reference in New Issue