@@ -11,13 +11,15 @@ | |||||
</PropertyGroup> | </PropertyGroup> | ||||
<PropertyGroup Label="Configuration"> | <PropertyGroup Label="Configuration"> | ||||
<CharacterSet>MultiByte</CharacterSet> | <CharacterSet>MultiByte</CharacterSet> | ||||
<UseOfMfc>Dynamic</UseOfMfc> | |||||
<UseOfMfc>false</UseOfMfc> | |||||
<ExceptionHandling>false</ExceptionHandling> | |||||
<FloatingPointModel>Fast</FloatingPointModel> | |||||
</PropertyGroup> | </PropertyGroup> | ||||
<PropertyGroup Condition="'$(Platform)'=='Win32'" Label="Configuration"> | <PropertyGroup Condition="'$(Platform)'=='Win32'" Label="Configuration"> | ||||
<PlatformToolset>v110</PlatformToolset> | |||||
<PlatformToolset>v120</PlatformToolset> | |||||
</PropertyGroup> | </PropertyGroup> | ||||
<PropertyGroup Condition="'$(Platform)'=='x64'" Label="Configuration"> | <PropertyGroup Condition="'$(Platform)'=='x64'" Label="Configuration"> | ||||
<PlatformToolset>v110</PlatformToolset> | |||||
<PlatformToolset>v120</PlatformToolset> | |||||
</PropertyGroup> | </PropertyGroup> | ||||
<PropertyGroup Condition="'$(Platform)'=='PS3'" Label="Configuration"> | <PropertyGroup Condition="'$(Platform)'=='PS3'" Label="Configuration"> | ||||
<PlatformToolset>SNC</PlatformToolset> | <PlatformToolset>SNC</PlatformToolset> | ||||
@@ -12,7 +12,9 @@ | |||||
<MultiProcessorCompilation>true</MultiProcessorCompilation> | <MultiProcessorCompilation>true</MultiProcessorCompilation> | ||||
<MinimalRebuild>false</MinimalRebuild> | <MinimalRebuild>false</MinimalRebuild> | ||||
<FloatingPointModel>Fast</FloatingPointModel> | |||||
<!-- We should use %(RelativeDir) here but for some reason it's an _absolute_ dir. WTF. --> | |||||
<ObjectFileName>$(IntDir)/%(Directory)/</ObjectFileName> | |||||
<AdditionalIncludeDirectories>$(SolutionDir)\..\..\src;$(SolutionDir)\..\..\src\bullet;$(FlexIncludes);$(BtPhysIncludes);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories> | <AdditionalIncludeDirectories>$(SolutionDir)\..\..\src;$(SolutionDir)\..\..\src\bullet;$(FlexIncludes);$(BtPhysIncludes);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories> | ||||
<AdditionalIncludeDirectories Condition="'$(Platform)'=='Win32'">$(GlIncludes);$(SdlIncludes);$(D3d9Includes);$(XinputIncludes);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories> | <AdditionalIncludeDirectories Condition="'$(Platform)'=='Win32'">$(GlIncludes);$(SdlIncludes);$(D3d9Includes);$(XinputIncludes);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories> | ||||
<AdditionalIncludeDirectories Condition="'$(Platform)'=='x64'">$(GlIncludes);$(SdlIncludes);$(D3d9Includes);$(XinputIncludes);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories> | <AdditionalIncludeDirectories Condition="'$(Platform)'=='x64'">$(GlIncludes);$(SdlIncludes);$(D3d9Includes);$(XinputIncludes);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories> | ||||
@@ -24,9 +24,7 @@ | |||||
#include <new> /* for placement new */ | #include <new> /* for placement new */ | ||||
#include <algorithm> /* for std::swap */ | #include <algorithm> /* for std::swap */ | ||||
#include <stdint.h> | #include <stdint.h> | ||||
#if 0 // disabled: Visual Studio 2012 doesn't have this | |||||
#include <initializer_list> | #include <initializer_list> | ||||
#endif | |||||
namespace lol | namespace lol | ||||
{ | { | ||||
@@ -49,7 +47,6 @@ public: | |||||
{ | { | ||||
} | } | ||||
#if 0 | |||||
inline ArrayBase(std::initializer_list<Element> list) | inline ArrayBase(std::initializer_list<Element> list) | ||||
: m_data(0), | : m_data(0), | ||||
m_count(0), | m_count(0), | ||||
@@ -59,7 +56,6 @@ public: | |||||
for (auto elem : list) | for (auto elem : list) | ||||
Push(elem); | Push(elem); | ||||
} | } | ||||
#endif | |||||
inline ~ArrayBase() | inline ~ArrayBase() | ||||
{ | { | ||||
@@ -143,6 +143,7 @@ | |||||
<ClCompile Include="image\codec\dummy-image.cpp" /> | <ClCompile Include="image\codec\dummy-image.cpp" /> | ||||
<ClCompile Include="image\codec\gdiplus-image.cpp" /> | <ClCompile Include="image\codec\gdiplus-image.cpp" /> | ||||
<ClCompile Include="image\codec\ios-image.cpp" /> | <ClCompile Include="image\codec\ios-image.cpp" /> | ||||
<ClCompile Include="image\codec\oric-image.cpp" /> | |||||
<ClCompile Include="image\codec\ps3-image.cpp" /> | <ClCompile Include="image\codec\ps3-image.cpp" /> | ||||
<ClCompile Include="image\codec\sdl-image.cpp" /> | <ClCompile Include="image\codec\sdl-image.cpp" /> | ||||
<ClCompile Include="image\codec\zed-image.cpp" /> | <ClCompile Include="image\codec\zed-image.cpp" /> | ||||
@@ -165,6 +165,9 @@ | |||||
<ClCompile Include="image\codec\ios-image.cpp"> | <ClCompile Include="image\codec\ios-image.cpp"> | ||||
<Filter>image\codec</Filter> | <Filter>image\codec</Filter> | ||||
</ClCompile> | </ClCompile> | ||||
<ClCompile Include="image\codec\oric-image.cpp"> | |||||
<Filter>image\codec</Filter> | |||||
</ClCompile> | |||||
<ClCompile Include="image\codec\ps3-image.cpp"> | <ClCompile Include="image\codec\ps3-image.cpp"> | ||||
<Filter>image\codec</Filter> | <Filter>image\codec</Filter> | ||||
</ClCompile> | </ClCompile> | ||||
@@ -53,6 +53,15 @@ LOLUNIT_FIXTURE(ArrayTest) | |||||
LOLUNIT_ASSERT_EQUAL(a[3], 3); | LOLUNIT_ASSERT_EQUAL(a[3], 3); | ||||
} | } | ||||
LOLUNIT_TEST(ArrayInitializer) | |||||
{ | |||||
Array<int> a = { 2, 4, 6 }; | |||||
LOLUNIT_ASSERT_EQUAL(a[0], 2); | |||||
LOLUNIT_ASSERT_EQUAL(a[1], 4); | |||||
LOLUNIT_ASSERT_EQUAL(a[2], 6); | |||||
} | |||||
LOLUNIT_TEST(ArrayPushWithShift) | LOLUNIT_TEST(ArrayPushWithShift) | ||||
{ | { | ||||
Array<int> a; | Array<int> a; | ||||