mirror of
https://github.com/ZDoom/gzdoom.git
synced 2024-11-11 07:12:02 +00:00
Added workaround for undefined isnan()
All our continuous integration targets have no problems with C99 isnan() macro but on Ubuntu 16.04 compilation fails It appeared that some implementation of C++ Standard Library may undefine bunch of C macros to avoid conflicts with own declarations
This commit is contained in:
parent
e865ba60f5
commit
020c34abfa
1 changed files with 7 additions and 0 deletions
|
@ -42,6 +42,13 @@
|
||||||
#include "swrenderer/r_renderthread.h"
|
#include "swrenderer/r_renderthread.h"
|
||||||
#include "swrenderer/r_memory.h"
|
#include "swrenderer/r_memory.h"
|
||||||
|
|
||||||
|
#ifndef isnan
|
||||||
|
// Fallback to C++ function if C99 isnan() macro is not undefined
|
||||||
|
// Most likely it was undefined in C++ library header to avoid conflicts with own function
|
||||||
|
#include <cmath>
|
||||||
|
using std::isnan;
|
||||||
|
#endif // !isnan
|
||||||
|
|
||||||
namespace swrenderer
|
namespace swrenderer
|
||||||
{
|
{
|
||||||
WallSampler::WallSampler(RenderViewport *viewport, int y1, double texturemid, float swal, double yrepeat, fixed_t xoffset, double xmagnitude, FTexture *texture)
|
WallSampler::WallSampler(RenderViewport *viewport, int y1, double texturemid, float swal, double yrepeat, fixed_t xoffset, double xmagnitude, FTexture *texture)
|
||||||
|
|
Loading…
Reference in a new issue