diff options
| author | Richard Smith <richard-llvm@metafoo.co.uk> | 2016-06-30 20:24:30 +0000 |
|---|---|---|
| committer | Richard Smith <richard-llvm@metafoo.co.uk> | 2016-06-30 20:24:30 +0000 |
| commit | b8c414ccd1e3571367aa2b002e29f8f38a939fa4 (patch) | |
| tree | d0a49134bf0ca9eca4eef81b8a0297416ba3128c /clang/test/SemaCXX/return.cpp | |
| parent | 5220d4e7608e8411e0be822c8d46d35767e7547c (diff) | |
| download | bcm5719-llvm-b8c414ccd1e3571367aa2b002e29f8f38a939fa4.tar.gz bcm5719-llvm-b8c414ccd1e3571367aa2b002e29f8f38a939fa4.zip | |
Fix typo-correction crash if a typo occurs within the operand of a
function-style cast to a non-dependent type which is then used in an invalid
way. We'd lose the "type dependent" bit here, and downstream Sema processing
would then discard the expression if it was used in a context where its type
rendered it invalid.
llvm-svn: 274267
Diffstat (limited to 'clang/test/SemaCXX/return.cpp')
| -rw-r--r-- | clang/test/SemaCXX/return.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/test/SemaCXX/return.cpp b/clang/test/SemaCXX/return.cpp index 8c1664516a7..db289240d1c 100644 --- a/clang/test/SemaCXX/return.cpp +++ b/clang/test/SemaCXX/return.cpp @@ -118,5 +118,5 @@ void cxx_unresolved_expr() { // CXXUnresolvedConstructExpr, and the missing ')' gives it an invalid source // location for its rparen. Check that emitting a diag on the range of the // expr doesn't assert. - return int(undeclared, 4; // expected-error {{expected ')'}} expected-note{{to match this '('}} expected-error {{void function 'cxx_unresolved_expr' should not return a value}} expected-error {{use of undeclared identifier 'undeclared'}} + return int(undeclared, 4; // expected-error {{expected ')'}} expected-note{{to match this '('}} expected-error {{use of undeclared identifier 'undeclared'}} } |

