diff options
| author | kipcode66 <kipcode66@gmail.com> | 2026-01-05 06:50:45 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2026-01-05 03:50:45 -0800 |
| commit | 1d2a0d956851e10549c56be039fd42f6f0937802 (patch) | |
| tree | a517d5e5f3a449599fa47fe59903a99d9ce49833 /include/SSystem | |
| parent | b897ed3ec9b63001ce74411569a087cacc4f23d9 (diff) | |
Add guards around std library headers (#3013)
* Last fix for standard compiler error
* adding define guards around headers
* rename cmath.h and climits.h to cmath and climits respectively
* renaming cstdarg.h to cstdarg
* renaming cstdlib.h to cstdlib
* renaming cstring.h to cstring
* renaming cstdio.h to cstdio
* renaming cmath locale ctype
* renaming stdarg string and va_list
* renaming cstddef
* renaming stdio stddef stdlib
* renaming algorithm, functional, iterator, memory, and utility
* renaming bitset, cstdint, limits, and stdint
* renaming new and type_traits
* update quote includes for standard library headers to angle bracket includes
Diffstat (limited to 'include/SSystem')
| -rw-r--r-- | include/SSystem/SComponent/c_m3d.h | 2 | ||||
| -rw-r--r-- | include/SSystem/SComponent/c_math.h | 7 | ||||
| -rw-r--r-- | include/SSystem/SComponent/c_xyz.h | 2 |
3 files changed, 9 insertions, 2 deletions
diff --git a/include/SSystem/SComponent/c_m3d.h b/include/SSystem/SComponent/c_m3d.h index 6634100209..a8045c74a7 100644 --- a/include/SSystem/SComponent/c_m3d.h +++ b/include/SSystem/SComponent/c_m3d.h @@ -1,7 +1,7 @@ #ifndef C_M3D_H_ #define C_M3D_H_ -#include <math.h> +#include <math> #include "dolphin/mtx.h" class cM3dGAab; diff --git a/include/SSystem/SComponent/c_math.h b/include/SSystem/SComponent/c_math.h index c525dfa7e4..0203b4e2f1 100644 --- a/include/SSystem/SComponent/c_math.h +++ b/include/SSystem/SComponent/c_math.h @@ -3,6 +3,13 @@ #include "JSystem/JMath/JMATrigonometric.h" +#ifndef __MWERKS__ +#include <limits> +#ifndef FLT_MAX +#define FLT_MAX std::numeric_limits<float>::max() +#endif +#endif + s16 cM_rad2s(float rad); u16 U_GetAtanTable(float, float); s16 cM_atan2s(float y, float x); diff --git a/include/SSystem/SComponent/c_xyz.h b/include/SSystem/SComponent/c_xyz.h index be2bf76935..838949cb13 100644 --- a/include/SSystem/SComponent/c_xyz.h +++ b/include/SSystem/SComponent/c_xyz.h @@ -2,7 +2,7 @@ #define C_XYZ_H #include "dolphin/mtx.h" -#include <math.h> +#include <math> struct cXyz : Vec { static const cXyz Zero; |
