diff options
| author | Sebastian Redl <sebastian.redl@getdesigned.at> | 2010-11-26 18:37:14 +0000 |
|---|---|---|
| committer | Sebastian Redl <sebastian.redl@getdesigned.at> | 2010-11-26 18:37:14 +0000 |
| commit | 002a3c506a4e2662c9c36ae60c2cbd912111db45 (patch) | |
| tree | b8f8740939f5c41359b80992f0123396249b2e2c | |
| parent | 9610ea943c7a0b07491332852bb6257dff803846 (diff) | |
| download | bcm5719-llvm-002a3c506a4e2662c9c36ae60c2cbd912111db45.tar.gz bcm5719-llvm-002a3c506a4e2662c9c36ae60c2cbd912111db45.zip | |
Forgot a file in r120182
llvm-svn: 120184
| -rw-r--r-- | clang/test/CXX/class/class.nest/p1-cxx0x.cpp | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/clang/test/CXX/class/class.nest/p1-cxx0x.cpp b/clang/test/CXX/class/class.nest/p1-cxx0x.cpp new file mode 100644 index 00000000000..f8b06ac5f7e --- /dev/null +++ b/clang/test/CXX/class/class.nest/p1-cxx0x.cpp @@ -0,0 +1,14 @@ +// RUN: %clang_cc1 -fsyntax-only -std=c++0x -verify %s + +class Outer { + int x; + static int sx; + int f(); + + // The first case is invalid in the C++03 mode but valid in C++0x (see 5.1.1.10). + class Inner { + static char a[sizeof(x)]; // okay + static char b[sizeof(sx)]; // okay + static char c[sizeof(f)]; // expected-error {{ call to non-static member function without an object argument }} + }; +}; |

