summaryrefslogtreecommitdiffhomepage
path: root/Magic2
diff options
context:
space:
mode:
authorYasha Jannoo <alledodo@gmail.com>2019-09-12 00:41:34 +0100
committerYasha Jannoo <alledodo@gmail.com>2019-09-12 00:41:34 +0100
commite31b0c1803d976e29b258c7307e32fd0d63821e5 (patch)
tree2bb72d12e8a7b56fbbba41c6cef71453b2bc8083 /Magic2
parent5d694ca25f75a8809290f6fbd865ef9fd1eec12c (diff)
downloadstarshatter-e31b0c1803d976e29b258c7307e32fd0d63821e5.zip
starshatter-e31b0c1803d976e29b258c7307e32fd0d63821e5.tar.gz
starshatter-e31b0c1803d976e29b258c7307e32fd0d63821e5.tar.bz2
Fix ill-formed and warning-causing new overloaded and delete operators
From VS2015 onwards, overloaded new and delete operators were no longer allowed to be declared inline. See https://docs.microsoft.com/en-us/cpp/porting/visual-cpp-what-s-new-2003-through-2015?view=vs-2019. As a consequence of moving the definitions into source files, we cannot simply include the headers in the files they are required in without also either creating a static library or including the source files in the projects. Do the latter as the pattern fits other examples of dependencies across projects in the solution. The overloaded operator definitions could be made neater in a future change. For now they are written as their declarations appear in the header file, with the same ifdefs as in the header file.
Diffstat (limited to 'Magic2')
-rw-r--r--Magic2/Magic.vcxproj2
-rw-r--r--Magic2/Magic.vcxproj.filters6
2 files changed, 8 insertions, 0 deletions
diff --git a/Magic2/Magic.vcxproj b/Magic2/Magic.vcxproj
index d1cac69..cda41e0 100644
--- a/Magic2/Magic.vcxproj
+++ b/Magic2/Magic.vcxproj
@@ -699,6 +699,7 @@
</ClCompile>
</ItemDefinitionGroup>
<ItemGroup>
+ <ClCompile Include="..\FoundationEx\MemDebug.cpp" />
<ClCompile Include="..\nGenEx\ActiveWindow.cpp" />
<ClCompile Include="AlphaInverse.cpp" />
<ClCompile Include="AlphaPalette.cpp" />
@@ -825,6 +826,7 @@
<ResourceCompile Include="Magic.rc" />
</ItemGroup>
<ItemGroup>
+ <ClInclude Include="..\FoundationEx\MemDebug.h" />
<ClInclude Include="..\nGenEx\AviFile.h" />
<ClInclude Include="Command.h" />
<ClInclude Include="ContentBundle.h" />
diff --git a/Magic2/Magic.vcxproj.filters b/Magic2/Magic.vcxproj.filters
index 1ed7515..a6b3503 100644
--- a/Magic2/Magic.vcxproj.filters
+++ b/Magic2/Magic.vcxproj.filters
@@ -315,6 +315,9 @@
<ClCompile Include="Locale_ss.cpp">
<Filter>Source Files</Filter>
</ClCompile>
+ <ClCompile Include="..\FoundationEx\MemDebug.cpp">
+ <Filter>Source Files</Filter>
+ </ClCompile>
</ItemGroup>
<ItemGroup>
<ResourceCompile Include="Magic.rc">
@@ -403,6 +406,9 @@
<ClInclude Include="Locale_ss.h">
<Filter>Header Files</Filter>
</ClInclude>
+ <ClInclude Include="..\FoundationEx\MemDebug.h">
+ <Filter>Header Files</Filter>
+ </ClInclude>
</ItemGroup>
<ItemGroup>
<CustomBuild Include="res\Magic.ico">