From 0013be16fff27ce7744210007e08ed7528212c65 Mon Sep 17 00:00:00 2001 From: Craig Topper Date: Mon, 21 Sep 2015 05:32:41 +0000 Subject: Use makeArrayRef or None to avoid unnecessarily mentioning the ArrayRef type extra times. NFC llvm-svn: 248140 --- llvm/lib/DebugInfo/DWARF/DWARFFormValue.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'llvm/lib/DebugInfo/DWARF/DWARFFormValue.cpp') diff --git a/llvm/lib/DebugInfo/DWARF/DWARFFormValue.cpp b/llvm/lib/DebugInfo/DWARF/DWARFFormValue.cpp index 53a676efaf3..d22e63502d2 100644 --- a/llvm/lib/DebugInfo/DWARF/DWARFFormValue.cpp +++ b/llvm/lib/DebugInfo/DWARF/DWARFFormValue.cpp @@ -110,7 +110,7 @@ static const DWARFFormValue::FormClass DWARF4FormClasses[] = { bool DWARFFormValue::isFormClass(DWARFFormValue::FormClass FC) const { // First, check DWARF4 form classes. - if (Form < ArrayRef(DWARF4FormClasses).size() && + if (Form < makeArrayRef(DWARF4FormClasses).size() && DWARF4FormClasses[Form] == FC) return true; // Check more forms from DWARF4 and DWARF5 proposals. @@ -584,6 +584,6 @@ Optional DWARFFormValue::getAsSignedConstant() const { Optional> DWARFFormValue::getAsBlock() const { if (!isFormClass(FC_Block) && !isFormClass(FC_Exprloc)) return None; - return ArrayRef(Value.data, Value.uval); + return makeArrayRef(Value.data, Value.uval); } -- cgit v1.2.3