mirror of
https://github.com/libsdl-org/SDL.git
synced 2026-07-16 22:11:07 +00:00
ecd15e953584aafe1727a45c1d10636f91d5e3e9
We don't care _what_ the `sizeof` results are, we just want it to vaporize
the condition's code out of the build. So we check it with a `? 1 : 0`, so it
always boils down to a `sizeof (int)`, no matter what data type the condition
actually is.
This works with bitfields, pointers, anything that can be "truthy." If it
isn't truthy, it would fail when assertions are enabled anyhow.
Fixes #15990.
(cherry picked from commit daf519ae05)
Simple DirectMedia Layer (SDL for short) is a cross-platform library designed to make it easy to write multi-media software, such as games and emulators.
You can find the latest release and additional information at: https://www.libsdl.org/
Installation instructions and a quick introduction is available in INSTALL.md
This library is distributed under the terms of the zlib license, available in LICENSE.txt.
Enjoy!
Sam Lantinga (slouken@libsdl.org)
Languages
C
87.7%
C++
4.2%
Objective-C
3.4%
CMake
1.7%
Java
0.8%
Other
1.9%