aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/Sema/SemaChecking.cpp
diff options
context:
space:
mode:
authorErich Keane <erich.keane@intel.com>2020-04-17 10:44:19 -0700
committerErich Keane <erich.keane@intel.com>2020-04-17 10:45:48 -0700
commit5f0903e9bec97e67bf34d887bcbe9d05790de934 (patch)
treef0e7c27a17af3f8ec0837b02160012bfc4177025 /clang/lib/Sema/SemaChecking.cpp
parent5f6d93c7d3165938ed4602013f4b89929b1f9682 (diff)
downloadllvm-5f0903e9bec97e67bf34d887bcbe9d05790de934.zip
llvm-5f0903e9bec97e67bf34d887bcbe9d05790de934.tar.gz
llvm-5f0903e9bec97e67bf34d887bcbe9d05790de934.tar.bz2
Reland Implement _ExtInt as an extended int type specifier.
I fixed the LLDB issue, so re-applying the patch. This reverts commit a4b88c044980337bb14390be654fe76864aa60ec.
Diffstat (limited to 'clang/lib/Sema/SemaChecking.cpp')
-rw-r--r--clang/lib/Sema/SemaChecking.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/clang/lib/Sema/SemaChecking.cpp b/clang/lib/Sema/SemaChecking.cpp
index e7bc499..037e9c3 100644
--- a/clang/lib/Sema/SemaChecking.cpp
+++ b/clang/lib/Sema/SemaChecking.cpp
@@ -9793,6 +9793,9 @@ struct IntRange {
false/*NonNegative*/);
}
+ if (const auto *EIT = dyn_cast<ExtIntType>(T))
+ return IntRange(EIT->getNumBits(), EIT->isUnsigned());
+
const BuiltinType *BT = cast<BuiltinType>(T);
assert(BT->isInteger());
@@ -9816,6 +9819,9 @@ struct IntRange {
if (const EnumType *ET = dyn_cast<EnumType>(T))
T = C.getCanonicalType(ET->getDecl()->getIntegerType()).getTypePtr();
+ if (const auto *EIT = dyn_cast<ExtIntType>(T))
+ return IntRange(EIT->getNumBits(), EIT->isUnsigned());
+
const BuiltinType *BT = cast<BuiltinType>(T);
assert(BT->isInteger());