aboutsummaryrefslogtreecommitdiff
path: root/lib/AST/ASTContext.cpp
diff options
context:
space:
mode:
authorEnea Zaffanella <zaffanella@cs.unipr.it>2013-01-26 17:08:37 +0000
committerEnea Zaffanella <zaffanella@cs.unipr.it>2013-01-26 17:08:37 +0000
commit9677eb864f7354f140cd1bf59557843851e65de4 (patch)
treea539421999e558f1126947a9847a86aabd076c48 /lib/AST/ASTContext.cpp
parentadeb7822cb7947194fef0e12d2d6583ccb8240b5 (diff)
Added ASTContext methods getIntPtrType and getUIntPtrType.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@173581 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/AST/ASTContext.cpp')
-rw-r--r--lib/AST/ASTContext.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/AST/ASTContext.cpp b/lib/AST/ASTContext.cpp
index 1d103f1129..7ba64e32f3 100644
--- a/lib/AST/ASTContext.cpp
+++ b/lib/AST/ASTContext.cpp
@@ -3589,6 +3589,14 @@ QualType ASTContext::getUnsignedWCharType() const {
return UnsignedIntTy;
}
+QualType ASTContext::getIntPtrType() const {
+ return getFromTargetType(Target->getIntPtrType());
+}
+
+QualType ASTContext::getUIntPtrType() const {
+ return getCorrespondingUnsignedType(getIntPtrType());
+}
+
/// getPointerDiffType - Return the unique type for "ptrdiff_t" (C99 7.17)
/// defined in <stddef.h>. Pointer - pointer requires this (C99 6.5.6p9).
QualType ASTContext::getPointerDiffType() const {