A couple of smallish fixes (PR #1029)

. Fix VS2008 build: int8_t is not defined
. Fix VC compile warning C4800: forcing int to bool
This commit is contained in:
Kelvin Lee 2022-02-06 09:02:26 +11:00 committed by GitHub
parent f7c6ef397c
commit ad73f3ec37
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 2 deletions

View File

@ -1765,8 +1765,8 @@ void updateScreenSHR(long cycles6502)
uint8_t* pControl = MemGetAuxPtr(0x9D00 + g_nVideoClockVert); // scan-line control byte
uint8_t c = pControl[0];
bool is640Mode = c & 0x80;
bool isColorFillMode = c & 0x20;
bool is640Mode = !!(c & 0x80);
bool isColorFillMode = !!(c & 0x20);
UINT paletteSelectCode = c & 0xf;
const UINT kColorsPerPalette = 16;
const UINT kColorSize = 2;

View File

@ -11,6 +11,7 @@
#if _MSC_VER >= 1600 // <stdint.h> supported from VS2010 (cl.exe v16.00)
#include <stdint.h> // cleanup WORD DWORD -> uint16_t uint32_t
#else
typedef INT8 int8_t;
typedef UINT8 uint8_t;
typedef UINT16 uint16_t;
typedef UINT32 uint32_t;