mirror of https://github.com/AxioDL/tinyxml2.git
Replaced pragmas with compiler define.
This commit is contained in:
parent
2f1f6247e0
commit
0922b7389f
|
@ -85,7 +85,7 @@
|
||||||
</PrecompiledHeader>
|
</PrecompiledHeader>
|
||||||
<WarningLevel>Level4</WarningLevel>
|
<WarningLevel>Level4</WarningLevel>
|
||||||
<Optimization>Disabled</Optimization>
|
<Optimization>Disabled</Optimization>
|
||||||
<PreprocessorDefinitions>WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
<PreprocessorDefinitions>WIN32;_DEBUG;_CONSOLE;_CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||||
<ExceptionHandling>false</ExceptionHandling>
|
<ExceptionHandling>false</ExceptionHandling>
|
||||||
</ClCompile>
|
</ClCompile>
|
||||||
<Link>
|
<Link>
|
||||||
|
@ -115,7 +115,7 @@
|
||||||
<Optimization>MaxSpeed</Optimization>
|
<Optimization>MaxSpeed</Optimization>
|
||||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||||
<PreprocessorDefinitions>WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
<PreprocessorDefinitions>WIN32;NDEBUG;_CONSOLE;_CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||||
<StringPooling>true</StringPooling>
|
<StringPooling>true</StringPooling>
|
||||||
</ClCompile>
|
</ClCompile>
|
||||||
<Link>
|
<Link>
|
||||||
|
|
41
xmltest.cpp
41
xmltest.cpp
|
@ -153,11 +153,6 @@ int main( int /*argc*/, const char ** /*argv*/ )
|
||||||
_CrtMemCheckpoint( &startMemState );
|
_CrtMemCheckpoint( &startMemState );
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined(_MSC_VER)
|
|
||||||
#pragma warning ( push )
|
|
||||||
#pragma warning ( disable : 4996 ) // Fail to see a compelling reason why this should be deprecated.
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#if defined(_MSC_VER)
|
#if defined(_MSC_VER)
|
||||||
_mkdir( "resources/out/" );
|
_mkdir( "resources/out/" );
|
||||||
#else
|
#else
|
||||||
|
@ -178,10 +173,6 @@ int main( int /*argc*/, const char ** /*argv*/ )
|
||||||
}
|
}
|
||||||
fclose( fp );
|
fclose( fp );
|
||||||
|
|
||||||
#if defined(_MSC_VER)
|
|
||||||
#pragma warning ( pop )
|
|
||||||
#endif
|
|
||||||
|
|
||||||
XMLTest( "Example-1", 0, example_1() );
|
XMLTest( "Example-1", 0, example_1() );
|
||||||
XMLTest( "Example-2", 0, example_2() );
|
XMLTest( "Example-2", 0, example_2() );
|
||||||
XMLTest( "Example-3", 0, example_3() );
|
XMLTest( "Example-3", 0, example_3() );
|
||||||
|
@ -424,16 +415,8 @@ int main( int /*argc*/, const char ** /*argv*/ )
|
||||||
// Check the round trip.
|
// Check the round trip.
|
||||||
int okay = 0;
|
int okay = 0;
|
||||||
|
|
||||||
|
|
||||||
#if defined(_MSC_VER)
|
|
||||||
#pragma warning ( push )
|
|
||||||
#pragma warning ( disable : 4996 ) // Fail to see a compelling reason why this should be deprecated.
|
|
||||||
#endif
|
|
||||||
FILE* saved = fopen( "resources/out/utf8testout.xml", "r" );
|
FILE* saved = fopen( "resources/out/utf8testout.xml", "r" );
|
||||||
FILE* verify = fopen( "resources/utf8testverify.xml", "r" );
|
FILE* verify = fopen( "resources/utf8testverify.xml", "r" );
|
||||||
#if defined(_MSC_VER)
|
|
||||||
#pragma warning ( pop )
|
|
||||||
#endif
|
|
||||||
|
|
||||||
if ( saved && verify )
|
if ( saved && verify )
|
||||||
{
|
{
|
||||||
|
@ -548,28 +531,15 @@ int main( int /*argc*/, const char ** /*argv*/ )
|
||||||
|
|
||||||
XMLTest( "Entity transformation: read. ", expected, context, true );
|
XMLTest( "Entity transformation: read. ", expected, context, true );
|
||||||
|
|
||||||
#if defined(_MSC_VER)
|
|
||||||
#pragma warning ( push )
|
|
||||||
#pragma warning ( disable : 4996 ) // Fail to see a compelling reason why this should be deprecated.
|
|
||||||
#endif
|
|
||||||
FILE* textfile = fopen( "resources/out/textfile.txt", "w" );
|
FILE* textfile = fopen( "resources/out/textfile.txt", "w" );
|
||||||
#if defined(_MSC_VER)
|
|
||||||
#pragma warning ( pop )
|
|
||||||
#endif
|
|
||||||
if ( textfile )
|
if ( textfile )
|
||||||
{
|
{
|
||||||
XMLPrinter streamer( textfile );
|
XMLPrinter streamer( textfile );
|
||||||
psg->Accept( &streamer );
|
psg->Accept( &streamer );
|
||||||
fclose( textfile );
|
fclose( textfile );
|
||||||
}
|
}
|
||||||
#if defined(_MSC_VER)
|
|
||||||
#pragma warning ( push )
|
textfile = fopen( "resources/out/textfile.txt", "r" );
|
||||||
#pragma warning ( disable : 4996 ) // Fail to see a compelling reason why this should be deprecated.
|
|
||||||
#endif
|
|
||||||
textfile = fopen( "resources/out/textfile.txt", "r" );
|
|
||||||
#if defined(_MSC_VER)
|
|
||||||
#pragma warning ( pop )
|
|
||||||
#endif
|
|
||||||
TIXMLASSERT( textfile );
|
TIXMLASSERT( textfile );
|
||||||
if ( textfile )
|
if ( textfile )
|
||||||
{
|
{
|
||||||
|
@ -980,14 +950,7 @@ int main( int /*argc*/, const char ** /*argv*/ )
|
||||||
QueryPerformanceFrequency( (LARGE_INTEGER*) &freq );
|
QueryPerformanceFrequency( (LARGE_INTEGER*) &freq );
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined(_MSC_VER)
|
|
||||||
#pragma warning ( push )
|
|
||||||
#pragma warning ( disable : 4996 ) // Fail to see a compelling reason why this should be deprecated.
|
|
||||||
#endif
|
|
||||||
FILE* fp = fopen( "resources/dream.xml", "r" );
|
FILE* fp = fopen( "resources/dream.xml", "r" );
|
||||||
#if defined(_MSC_VER)
|
|
||||||
#pragma warning ( pop )
|
|
||||||
#endif
|
|
||||||
fseek( fp, 0, SEEK_END );
|
fseek( fp, 0, SEEK_END );
|
||||||
long size = ftell( fp );
|
long size = ftell( fp );
|
||||||
fseek( fp, 0, SEEK_SET );
|
fseek( fp, 0, SEEK_SET );
|
||||||
|
|
Loading…
Reference in New Issue