From 981b9521eadc49bf30b8f06a47335df3bea1d4f5 Mon Sep 17 00:00:00 2001 From: Vitaly Novichkov Date: Fri, 27 Apr 2018 02:41:58 +0300 Subject: Fixed MSVC build --- src/chips/opl_chip_base.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'src/chips') diff --git a/src/chips/opl_chip_base.h b/src/chips/opl_chip_base.h index 75dd903..fb9b9e9 100644 --- a/src/chips/opl_chip_base.h +++ b/src/chips/opl_chip_base.h @@ -4,8 +4,7 @@ #include #include -/* TODO: MSVC: Use MSVC versioing instead of this to detect does it supports those C++11 keywords or not */ -#if __cplusplus <= 199711L +#if !defined(_MSC_VER) && (__cplusplus <= 199711L) #define final #define override #endif -- cgit v1.2.3 From 649c9dcc2ba53a0be994318999beb905c0c14528 Mon Sep 17 00:00:00 2001 From: Vitaly Novichkov Date: Fri, 27 Apr 2018 02:42:29 +0300 Subject: Fixed MinGW-w64 build of DosBox emulator --- src/chips/dosbox/dbopl.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'src/chips') diff --git a/src/chips/dosbox/dbopl.cpp b/src/chips/dosbox/dbopl.cpp index 8834524..3e21772 100644 --- a/src/chips/dosbox/dbopl.cpp +++ b/src/chips/dosbox/dbopl.cpp @@ -1875,8 +1875,8 @@ namespace DBOPL if(i >= 16) index += 9; - Bitu blah = reinterpret_cast(&(chip->chan[ index ])); - ChanOffsetTable[i] = blah; + intptr_t blah = reinterpret_cast(&(chip->chan[ index ])); + ChanOffsetTable[i] = static_cast(blah); } //Same for operators @@ -1895,9 +1895,9 @@ namespace DBOPL chNum += 16 - 12; Bitu opNum = (i % 8) / 3; - DBOPL::Channel *chan = 0; - Bitu blah = reinterpret_cast(&(chan->op[opNum])); - OpOffsetTable[i] = ChanOffsetTable[ chNum ] + blah; + DBOPL::Channel *chan = NULL; + intptr_t blah = reinterpret_cast(&(chan->op[opNum])); + OpOffsetTable[i] = static_cast((intptr_t)ChanOffsetTable[ chNum ] + blah); } #if 0 -- cgit v1.2.3