diff options
author | David Blaikie <dblaikie@gmail.com> | 2011-11-07 03:27:58 +0000 |
---|---|---|
committer | David Blaikie <dblaikie@gmail.com> | 2011-11-07 03:27:58 +0000 |
commit | b06c68d320b943c6c1eea1811b61faed5b873c2c (patch) | |
tree | 7c7556b0c0f5a1707503be3d61423f1b7366f110 /clang/test/CXX/expr/expr.prim/expr.prim.general/p12-0x.cpp | |
parent | a08acd8588e461df6ad74af3c5bd3ad1cc4149af (diff) | |
download | bcm5719-llvm-b06c68d320b943c6c1eea1811b61faed5b873c2c.tar.gz bcm5719-llvm-b06c68d320b943c6c1eea1811b61faed5b873c2c.zip |
Move tests to the appropriate directory to match the spec hierarchy.
llvm-svn: 143906
Diffstat (limited to 'clang/test/CXX/expr/expr.prim/expr.prim.general/p12-0x.cpp')
-rw-r--r-- | clang/test/CXX/expr/expr.prim/expr.prim.general/p12-0x.cpp | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/clang/test/CXX/expr/expr.prim/expr.prim.general/p12-0x.cpp b/clang/test/CXX/expr/expr.prim/expr.prim.general/p12-0x.cpp new file mode 100644 index 00000000000..aec62ddd97a --- /dev/null +++ b/clang/test/CXX/expr/expr.prim/expr.prim.general/p12-0x.cpp @@ -0,0 +1,12 @@ +// RUN: %clang_cc1 -fsyntax-only -verify -std=c++11 %s + +struct S { + int *j = &nonexistent; // expected-error {{use of undeclared identifier 'nonexistent'}} + int *m = &n; // ok + + int n = f(); // ok + int f(); +}; + +int i = sizeof(S::m); // ok +int j = sizeof(S::m + 42); // ok |