aboutsummaryrefslogtreecommitdiff
path: root/src/zig_clang.cpp
diff options
context:
space:
mode:
authorAndrew Kelley <andrew@ziglang.org>2020-01-27 13:32:39 -0500
committerAndrew Kelley <andrew@ziglang.org>2020-01-27 13:32:39 -0500
commite2778c03e07c23d60861b90474859b9d8a62bce8 (patch)
treeacd9f43605fcbea6fe9d1edf4694081fc003f819 /src/zig_clang.cpp
parent1a08c0d40b8c6e72532762281365a5105116dc00 (diff)
parentd8965002593c111069862e7de06402ee77b2b614 (diff)
downloadzig-e2778c03e07c23d60861b90474859b9d8a62bce8.tar.gz
zig-e2778c03e07c23d60861b90474859b9d8a62bce8.zip
Merge branch 'master' into ir-clean-up-vars
Diffstat (limited to 'src/zig_clang.cpp')
-rw-r--r--src/zig_clang.cpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/zig_clang.cpp b/src/zig_clang.cpp
index 5769d2fc73..8a1baa2d49 100644
--- a/src/zig_clang.cpp
+++ b/src/zig_clang.cpp
@@ -1625,6 +1625,10 @@ unsigned ZigClangFunctionDecl_getAlignedAttribute(const struct ZigClangFunctionD
return 0;
}
+ZigClangQualType ZigClangParmVarDecl_getOriginalType(const struct ZigClangParmVarDecl *self) {
+ return bitcast(reinterpret_cast<const clang::ParmVarDecl *>(self)->getOriginalType());
+}
+
const ZigClangRecordDecl *ZigClangRecordDecl_getDefinition(const ZigClangRecordDecl *zig_record_decl) {
const clang::RecordDecl *record_decl = reinterpret_cast<const clang::RecordDecl *>(zig_record_decl);
const clang::RecordDecl *definition = record_decl->getDefinition();
@@ -1877,6 +1881,11 @@ bool ZigClangType_isRecordType(const ZigClangType *self) {
return casted->isRecordType();
}
+bool ZigClangType_isConstantArrayType(const ZigClangType *self) {
+ auto casted = reinterpret_cast<const clang::Type *>(self);
+ return casted->isConstantArrayType();
+}
+
const char *ZigClangType_getTypeClassName(const ZigClangType *self) {
auto casted = reinterpret_cast<const clang::Type *>(self);
return casted->getTypeClassName();