]> granicus.if.org Git - clang/commit
Fix a theoretical bug when ParseCompoundStatement() returns StmtError.
authorNico Weber <nicolasweber@gmx.de>
Mon, 9 Mar 2015 03:17:15 +0000 (03:17 +0000)
committerNico Weber <nicolasweber@gmx.de>
Mon, 9 Mar 2015 03:17:15 +0000 (03:17 +0000)
commit0bf9e4ff0b534b8a9e310dd5debb33da82da22fb
treeb766d4e7371d85e4053ef196c091a705b2770d79
parentf82ff2549c0d3e123333cd1e68819dc7d98d375f
Fix a theoretical bug when ParseCompoundStatement() returns StmtError.

ParseCompoundStatement() currently never returns StmtError, but if it did,
Sema would keep the __finally scope on its stack indefinitely.  Explicitly
add an error callback that clears it.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@231625 91177308-0d34-0410-b5e6-96231b3b80d8
include/clang/Sema/Sema.h
lib/Parse/ParseStmt.cpp
lib/Sema/SemaStmt.cpp