Skip to content
Myr

msvc 64-bit fixes

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by r-lyeh · committed by r-lyeh · parent b53c08a · Browse files · 1 file+3 added−3 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+3 added−3 removed

  • other:+3 added−3 removed

1 file+3 added−3 removed

modified:stb.h+3 added-3 removed
1021 unmodified lines
1022 va_end(a);1023 fputs("\n", stderr);1024 #ifdef _WIN321025 #ifdef STB_DEBUG1026 __asm int 3; // trap to debugger!1026 __debugbreak; // trap to debugger!1027 #endif1028 #endif1029 exit(1);1030}
369 unmodified lines
1400#pragma warning(disable: 4035) // disable warning about no return value1401int stb_log2_floor(unsigned int n)1402{1403 #if _MSC_VER > 17001404 DWORD i;1404 unsigned int i;1405 _BitScanReverse(&i, n);1406 return i != 0 ? i : -1;1407 #else1408 __asm {
5949 unmodified lines
7358} stb_ps_bucket;7359#define GetBucket(p) ((stb_ps_bucket *) ((char *) (p) - STB_ps_bucket))7360#define EncodeBucket(p) ((stb_ps *) ((char *) (p) + STB_ps_bucket))73617362typedef char stb__verify_bucket_heap_size[sizeof(stb_ps_bucket) == 16];7362typedef char stb__verify_bucket_heap_size[sizeof(stb_ps_bucket) >= 16];73637364static void stb_bucket_free(stb_ps_bucket *b)7365{7366 free(b);
6720 unmodified lines