summaryrefslogtreecommitdiffstats
path: root/test/SemaCXX/lambda-expressions.cpp
diff options
context:
space:
mode:
authordim <dim@FreeBSD.org>2014-05-11 18:26:10 +0000
committerdim <dim@FreeBSD.org>2014-05-11 18:26:10 +0000
commit88f7a7d5251a2d813460274c92decc143a11569b (patch)
treec89fa0adefb99f464eba263b447f84c2ceb663ce /test/SemaCXX/lambda-expressions.cpp
parentfcddf668e724f57e5d75dc641bba534c6a21cd0d (diff)
downloadFreeBSD-src-88f7a7d5251a2d813460274c92decc143a11569b.zip
FreeBSD-src-88f7a7d5251a2d813460274c92decc143a11569b.tar.gz
Vendor import of clang RELEASE_34/dot1-final tag r208032 (effectively, 3.4.1 release):
https://llvm.org/svn/llvm-project/cfe/tags/RELEASE_34/dot1-final@208032
Diffstat (limited to 'test/SemaCXX/lambda-expressions.cpp')
-rw-r--r--test/SemaCXX/lambda-expressions.cpp17
1 files changed, 16 insertions, 1 deletions
diff --git a/test/SemaCXX/lambda-expressions.cpp b/test/SemaCXX/lambda-expressions.cpp
index e290424..65f4856 100644
--- a/test/SemaCXX/lambda-expressions.cpp
+++ b/test/SemaCXX/lambda-expressions.cpp
@@ -282,4 +282,19 @@ namespace lambdas_in_NSDMIs {
};
L l;
}
-} \ No newline at end of file
+}
+
+namespace PR18473 {
+ template<typename T> void f() {
+ T t(0);
+ (void) [=]{ int n = t; }; // expected-error {{deleted}}
+ }
+
+ template void f<int>();
+ struct NoCopy {
+ NoCopy(int);
+ NoCopy(const NoCopy &) = delete; // expected-note {{deleted}}
+ operator int() const;
+ };
+ template void f<NoCopy>(); // expected-note {{instantiation}}
+}
OpenPOWER on IntegriCloud