summaryrefslogtreecommitdiff
path: root/lib/CodeGen/CGExprAgg.cpp
diff options
context:
space:
mode:
authorDmitri Gribenko <gribozavr@gmail.com>2014-02-12 19:12:37 +0000
committerDmitri Gribenko <gribozavr@gmail.com>2014-02-12 19:12:37 +0000
commitb670b9b849e8528e77dc65f67652c8513708f4f0 (patch)
tree81059382c0faa4568f622e3477471aea5b38283a /lib/CodeGen/CGExprAgg.cpp
parente4022bf2ed043db77289bdaf7285c98076e3aa12 (diff)
downloadclang-b670b9b849e8528e77dc65f67652c8513708f4f0.tar.gz
clang-b670b9b849e8528e77dc65f67652c8513708f4f0.tar.bz2
clang-b670b9b849e8528e77dc65f67652c8513708f4f0.tar.xz
libclang: report error code for bad PCH files
This commit improves libclang to report the error condition when CXTranslationUnit can not be created because of a stale PCH file. This allows the caller, for example, to rebuild the PCH file and retry the request. There two are APIs in libclang that return a CXTranslationUnit and don't support reporting detailed errors (the only error condition is a NULL result). For these APIs, a second, superior, version is introduced -- clang_createTranslationUnit2 and clang_parseTranslationUnit2. These functions return a CXTranslationUnit indirectly and also return an error code. Old functions are still supported and are nothing more than convenience wrappers that ignore extended error codes. As a cleanup, this commit also categorizes some libclang errors in the functions I had to modify anyway. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@201249 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CGExprAgg.cpp')
0 files changed, 0 insertions, 0 deletions