aboutsummaryrefslogtreecommitdiff
path: root/test/Parser/cxx0x-lambda-expressions.cpp
diff options
context:
space:
mode:
authorRichard Smith <richard-llvm@metafoo.co.uk>2012-08-30 13:13:20 +0000
committerRichard Smith <richard-llvm@metafoo.co.uk>2012-08-30 13:13:20 +0000
commit3bc22262af7b09a459b400976cfce3d9318b8ea9 (patch)
tree51faf4fec3ac6fc33106849387c6b60f9c40d518 /test/Parser/cxx0x-lambda-expressions.cpp
parent6f79420b8650c807a8c3f6c553d6bb9319139c8d (diff)
PR13652: Don't assume the parameter array on a FunctionTypeLoc for a lambda will
be filled in; they won't if the lambda's declarator has an invalid type. Instead take the parameters from the declarator directly. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@162904 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Parser/cxx0x-lambda-expressions.cpp')
-rw-r--r--test/Parser/cxx0x-lambda-expressions.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/test/Parser/cxx0x-lambda-expressions.cpp b/test/Parser/cxx0x-lambda-expressions.cpp
index 7e9d4751e6..82b26534a1 100644
--- a/test/Parser/cxx0x-lambda-expressions.cpp
+++ b/test/Parser/cxx0x-lambda-expressions.cpp
@@ -26,6 +26,7 @@ class C {
[] -> int { return 0; }; // expected-error{{lambda requires '()' before return type}}
[] mutable -> int { return 0; }; // expected-error{{lambda requires '()' before 'mutable'}}
+ [](int) -> {}; // PR13652 expected-error {{expected a type}}
return 1;
}