forked from boostorg/typeof
little changes to avoid warnings
[SVN r2409]
This commit is contained in:
@@ -1,3 +1,5 @@
|
||||
#pragma warning(disable:4512)
|
||||
|
||||
#include <boost/typeof/typeof.hpp>
|
||||
|
||||
#include "spirit/register.hpp"
|
||||
@@ -13,7 +15,9 @@ void test_lambda()
|
||||
|
||||
BOOST_AUTO(fun, _1 > 15 && _2 < 20);
|
||||
int n = 19;
|
||||
//assert(fun(n, n));
|
||||
|
||||
if (!fun(n, n))
|
||||
throw 0;
|
||||
|
||||
std::cout << typeid(fun).name() << std::endl;
|
||||
}
|
||||
@@ -54,7 +58,8 @@ void test_spirit2()
|
||||
"/*this is a comment*/\n//this is a c++ comment\n\n",
|
||||
*skipper).full;
|
||||
|
||||
//assert(success);
|
||||
if (!success)
|
||||
throw 0;
|
||||
}
|
||||
|
||||
|
||||
|
@@ -25,7 +25,8 @@
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="5"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
WarningLevel="4"
|
||||
WarnAsError="TRUE"
|
||||
Detect64BitPortabilityProblems="TRUE"
|
||||
DebugInformationFormat="4"/>
|
||||
<Tool
|
||||
|
@@ -70,6 +70,9 @@ BOOST_STATIC_ASSERT(typeof_test<double(*)(int, double, short, char*, bool, char,
|
||||
BOOST_STATIC_ASSERT(typeof_test<void(*)()>::value);
|
||||
BOOST_STATIC_ASSERT(typeof_test<void(*)(int, double, short, char*, bool, char, float, long, unsigned short)>::value);
|
||||
|
||||
#pragma message("function references...")
|
||||
BOOST_STATIC_ASSERT(typeof_test<int&>::value);
|
||||
|
||||
#pragma message("member functions...")
|
||||
BOOST_STATIC_ASSERT(typeof_test<double(x::*)()>::value);
|
||||
BOOST_STATIC_ASSERT(typeof_test<double(x::*)(int, double, short, char*, bool, char, float, long, unsigned short)>::value);
|
||||
@@ -78,7 +81,6 @@ BOOST_STATIC_ASSERT(typeof_test<void(x::*)(int, double, short, char*, bool, char
|
||||
BOOST_STATIC_ASSERT(typeof_test<double(x::*)()const>::value);
|
||||
BOOST_STATIC_ASSERT(typeof_test<double(x::*)()volatile>::value);
|
||||
BOOST_STATIC_ASSERT(typeof_test<double(x::*)()volatile const>::value);
|
||||
//BOOST_STATIC_ASSERT(typeof_test<static double(x::*)()volatile const>::value);
|
||||
|
||||
#pragma message("data members...")
|
||||
BOOST_STATIC_ASSERT(typeof_test<double x::*>::value);
|
||||
@@ -130,6 +132,7 @@ struct noncopiable_test
|
||||
#else
|
||||
BOOST_AUTO(const& v, foo());
|
||||
#endif
|
||||
v; // to avoid warning
|
||||
}
|
||||
};
|
||||
|
||||
|
Reference in New Issue
Block a user