prime/include/Kyoto/Basics/CBasics.hpp

18 lines
342 B
C++
Raw Normal View History

#ifndef _CBASICS
#define _CBASICS
#include "types.h"
namespace CBasics {
2022-10-02 07:43:00 +00:00
void Init();
char* Stringize(const char* fmt, ...);
inline void SwapBytes(uchar* v) {}
inline float SwapBytes(float f) {
u8* tmp = reinterpret_cast<u8*>(&f);
SwapBytes(tmp);
return *reinterpret_cast<float*>(tmp);
}
}; // namespace CBasics
#endif // _CBASICS