summaryrefslogtreecommitdiffstats
path: root/clang/test/SemaCXX/new-delete.cpp
diff options
context:
space:
mode:
authorRichard Smith <richard-llvm@metafoo.co.uk>2014-01-19 23:25:37 +0000
committerRichard Smith <richard-llvm@metafoo.co.uk>2014-01-19 23:25:37 +0000
commitf600441a04997258368f87df4bebddf93d69da33 (patch)
tree3caef1a0c198c18b2a6d2c8c90c351961f07ac07 /clang/test/SemaCXX/new-delete.cpp
parent8347c34e672ab874b6dd35b2819b91cebe95d874 (diff)
downloadbcm5719-llvm-f600441a04997258368f87df4bebddf93d69da33.tar.gz
bcm5719-llvm-f600441a04997258368f87df4bebddf93d69da33.zip
PR18544: don't assert that 'operator new' is not declared inside a namespace;
such an assert will fail in invalid code that does so! llvm-svn: 199617
Diffstat (limited to 'clang/test/SemaCXX/new-delete.cpp')
-rw-r--r--clang/test/SemaCXX/new-delete.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/clang/test/SemaCXX/new-delete.cpp b/clang/test/SemaCXX/new-delete.cpp
index 59e2574fa14..175ebe7fcda 100644
--- a/clang/test/SemaCXX/new-delete.cpp
+++ b/clang/test/SemaCXX/new-delete.cpp
@@ -517,3 +517,7 @@ class DeletingPlaceholder {
return 0;
}
};
+
+namespace PR18544 {
+ inline void *operator new(size_t); // expected-error {{'operator new' cannot be declared inside a namespace}}
+}
OpenPOWER on IntegriCloud