diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2013-12-22 00:07:40 +0000 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2013-12-22 00:07:40 +0000 |
commit | bfef399519ca9b8a4b4c6b563253bad7e0eeffe0 (patch) | |
tree | df8df0b0067b381eab470a3b8f28d14a552a6340 /test/CXX/expr/expr.prim/expr.prim.lambda/p8.cpp | |
parent | 6a0372513edbc473b538d2f724efac50405d6fef (diff) |
Diffstat (limited to 'test/CXX/expr/expr.prim/expr.prim.lambda/p8.cpp')
-rw-r--r-- | test/CXX/expr/expr.prim/expr.prim.lambda/p8.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/test/CXX/expr/expr.prim/expr.prim.lambda/p8.cpp b/test/CXX/expr/expr.prim/expr.prim.lambda/p8.cpp index d1384f19dd14..b9b8cd76c011 100644 --- a/test/CXX/expr/expr.prim/expr.prim.lambda/p8.cpp +++ b/test/CXX/expr/expr.prim/expr.prim.lambda/p8.cpp @@ -1,4 +1,4 @@ -// RUN: %clang_cc1 -std=c++11 %s -verify +// RUN: %clang_cc1 -std=c++11 %s -verify -Wno-c++1y-extensions class X0 { void explicit_capture() { @@ -26,4 +26,7 @@ void S2::f(int i) { (void)[=, this]{ }; // expected-error{{'this' cannot be explicitly captured}} (void)[=]{ this->g(i); }; (void)[i, i]{ }; // expected-error{{'i' can appear only once in a capture list}} + (void)[i(0), i(1)]{ }; // expected-error{{'i' can appear only once in a capture list}} + (void)[i, i(1)]{ }; // expected-error{{'i' can appear only once in a capture list}} + (void)[i(0), i]{ }; // expected-error{{'i' can appear only once in a capture list}} } |