diff options
author | Chris Lattner <sabre@nondot.org> | 2010-09-01 15:49:26 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2010-09-01 15:49:26 +0000 |
commit | 0073962025603d76fd89129c1c1cdbe8228db97e (patch) | |
tree | 0b19ee4ad30c6564e3c6546faf3894bdc01e7034 /clang/lib | |
parent | 2333b12c8adde0c9fe9c52aa5a650a9a5011d9ab (diff) | |
download | bcm5719-llvm-0073962025603d76fd89129c1c1cdbe8228db97e.tar.gz bcm5719-llvm-0073962025603d76fd89129c1c1cdbe8228db97e.zip |
when emitting an error about a missing } in a compound statement, emit
a "to match this {" note, pointing out the opener.
llvm-svn: 112709
Diffstat (limited to 'clang/lib')
-rw-r--r-- | clang/lib/Parse/ParseStmt.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/clang/lib/Parse/ParseStmt.cpp b/clang/lib/Parse/ParseStmt.cpp index af927285a49..6c240e608c2 100644 --- a/clang/lib/Parse/ParseStmt.cpp +++ b/clang/lib/Parse/ParseStmt.cpp @@ -519,6 +519,7 @@ StmtResult Parser::ParseCompoundStatementBody(bool isStmtExpr) { // We broke out of the while loop because we found a '}' or EOF. if (Tok.isNot(tok::r_brace)) { Diag(Tok, diag::err_expected_rbrace); + Diag(LBraceLoc, diag::note_matching) << "{"; return StmtError(); } |