Don't enable GCC C++0x features in non-C++0x mode.

Update tests to actually fail unless we're in C++0x mode.
Fixes #5320.
Fixes #5319.

[SVN r70019]
This commit is contained in:
John Maddock
2011-03-16 18:45:07 +00:00
parent 2edb55f8ad
commit 050da29d47
5 changed files with 17 additions and 10 deletions
+4
View File
@@ -10,6 +10,10 @@
// TITLE: C++0x defaulted functions unavailable
// DESCRIPTION: The compiler does not support C++0x defaulted functions
#if defined(__GNUC__) && !defined(__GXX_EXPERIMENTAL_CXX0X__)
# error Defaulted functions aren't really supported in non-C++0x mode
#endif
namespace boost_no_defaulted_functions {
struct foo {
+4
View File
@@ -10,6 +10,10 @@
// TITLE: C++0x =delete functions unavailable
// DESCRIPTION: The compiler does not support C++0x =delete functions
#if defined(__GNUC__) && !defined(__GXX_EXPERIMENTAL_CXX0X__)
# error Deleted functions aren't really supported in non-C++0x mode
#endif
namespace boost_no_deleted_functions {
struct foo {
+4
View File
@@ -10,6 +10,10 @@
// TITLE: C++0x explicit conversion operators unavailable
// DESCRIPTION: The compiler does not support C++0x explicit conversion operators
#if defined(__GNUC__) && !defined(__GXX_EXPERIMENTAL_CXX0X__)
# error This feature isn't really available in non-C++0x mode
#endif
namespace boost_no_explicit_conversion_operators {
struct foo {
+4
View File
@@ -10,6 +10,10 @@
// TITLE: C++0x lambda feature unavailable
// DESCRIPTION: The compiler does not support the C++0x lambda feature
#if defined(__GNUC__) && !defined(__GXX_EXPERIMENTAL_CXX0X__)
# error This feature isn't really available in non-C++0x mode
#endif
namespace boost_no_lambdas {
int test()