[llvm] b0763a1 - [DebugInfo] Use std::size (NFC)
Kazu Hirata via llvm-commits
llvm-commits at lists.llvm.org
Wed Jan 24 00:27:49 PST 2024
Author: Kazu Hirata
Date: 2024-01-24T00:27:38-08:00
New Revision: b0763a1ae940d60d8f558f85216382bc6695a1e3
URL: https://github.com/llvm/llvm-project/commit/b0763a1ae940d60d8f558f85216382bc6695a1e3
DIFF: https://github.com/llvm/llvm-project/commit/b0763a1ae940d60d8f558f85216382bc6695a1e3.diff
LOG: [DebugInfo] Use std::size (NFC)
Added:
Modified:
llvm/lib/DebugInfo/DWARF/DWARFFormValue.cpp
Removed:
################################################################################
diff --git a/llvm/lib/DebugInfo/DWARF/DWARFFormValue.cpp b/llvm/lib/DebugInfo/DWARF/DWARFFormValue.cpp
index 29949ee021456df..b9cf7d22c80d4b8 100644
--- a/llvm/lib/DebugInfo/DWARF/DWARFFormValue.cpp
+++ b/llvm/lib/DebugInfo/DWARF/DWARFFormValue.cpp
@@ -761,8 +761,7 @@ DWARFFormValue::getAsFile(DILineInfoSpecifier::FileLineInfoKind Kind) const {
bool llvm::dwarf::doesFormBelongToClass(dwarf::Form Form, DWARFFormValue::FormClass FC,
uint16_t DwarfVersion) {
// First, check DWARF5 form classes.
- if (Form < ArrayRef(DWARF5FormClasses).size() &&
- DWARF5FormClasses[Form] == FC)
+ if (Form < std::size(DWARF5FormClasses) && DWARF5FormClasses[Form] == FC)
return true;
// Check more forms from extensions and proposals.
switch (Form) {
More information about the llvm-commits
mailing list