summaryrefslogtreecommitdiffstats
path: root/clang/include/clang-c/Index.h
diff options
context:
space:
mode:
authorEmilio Cobos Alvarez <emilio@crisal.io>2019-02-26 15:04:18 +0000
committerEmilio Cobos Alvarez <emilio@crisal.io>2019-02-26 15:04:18 +0000
commit0d76dc285c17c3e87994e46e4e0dc8383c755e4b (patch)
tree6df0b7408f9c6ba05a6594c1fd3c76994539fb04 /clang/include/clang-c/Index.h
parent582d46328ce644d791f4dce31b005fc260d33611 (diff)
downloadbcm5719-llvm-0d76dc285c17c3e87994e46e4e0dc8383c755e4b.tar.gz
bcm5719-llvm-0d76dc285c17c3e87994e46e4e0dc8383c755e4b.zip
[libclang] Avoid crashing when getting layout info of an undeduced type.
When the type is not deducible, return an error instead of crashing. This fixes https://bugs.llvm.org/show_bug.cgi?id=40813. Differential Revision: https://reviews.llvm.org/D58569 llvm-svn: 354885
Diffstat (limited to 'clang/include/clang-c/Index.h')
-rw-r--r--clang/include/clang-c/Index.h8
1 files changed, 6 insertions, 2 deletions
diff --git a/clang/include/clang-c/Index.h b/clang/include/clang-c/Index.h
index e6555fae78a..a5ef2d20587 100644
--- a/clang/include/clang-c/Index.h
+++ b/clang/include/clang-c/Index.h
@@ -32,7 +32,7 @@
* compatible, thus CINDEX_VERSION_MAJOR is expected to remain stable.
*/
#define CINDEX_VERSION_MAJOR 0
-#define CINDEX_VERSION_MINOR 52
+#define CINDEX_VERSION_MINOR 53
#define CINDEX_VERSION_ENCODE(major, minor) ( \
((major) * 10000) \
@@ -3841,7 +3841,11 @@ enum CXTypeLayoutError {
/**
* The Field name is not valid for this record.
*/
- CXTypeLayoutError_InvalidFieldName = -5
+ CXTypeLayoutError_InvalidFieldName = -5,
+ /**
+ * The type is undeduced.
+ */
+ CXTypeLayoutError_Undeduced = -6
};
/**
OpenPOWER on IntegriCloud