Use makeArrayRef or None to avoid unnecessarily mentioning the ArrayRef type extra times. NFC

llvm-svn: 248140
This commit is contained in:
Craig Topper
2015-09-21 05:32:41 +00:00
parent 18929c5069
commit 0013be16ff
13 changed files with 38 additions and 39 deletions

View File

@@ -218,7 +218,7 @@ static void dumpCXXData(const ObjectFile *Obj) {
// Complete object locators in the MS-ABI start with '??_R4'
else if (SymName.startswith("??_R4")) {
CompleteObjectLocator COL;
COL.Data = ArrayRef<little32_t>(
COL.Data = makeArrayRef(
reinterpret_cast<const little32_t *>(SymContents.data()), 3);
StringRef *I = std::begin(COL.Symbols), *E = std::end(COL.Symbols);
collectRelocatedSymbols(Obj, Sec, SecAddress, SymAddress, SymSize, I, E);
@@ -227,7 +227,7 @@ static void dumpCXXData(const ObjectFile *Obj) {
// Class hierarchy descriptors in the MS-ABI start with '??_R3'
else if (SymName.startswith("??_R3")) {
ClassHierarchyDescriptor CHD;
CHD.Data = ArrayRef<little32_t>(
CHD.Data = makeArrayRef(
reinterpret_cast<const little32_t *>(SymContents.data()), 3);
StringRef *I = std::begin(CHD.Symbols), *E = std::end(CHD.Symbols);
collectRelocatedSymbols(Obj, Sec, SecAddress, SymAddress, SymSize, I, E);
@@ -243,7 +243,7 @@ static void dumpCXXData(const ObjectFile *Obj) {
// Base class descriptors in the MS-ABI start with '??_R1'
else if (SymName.startswith("??_R1")) {
BaseClassDescriptor BCD;
BCD.Data = ArrayRef<little32_t>(
BCD.Data = makeArrayRef(
reinterpret_cast<const little32_t *>(SymContents.data()) + 1, 5);
StringRef *I = std::begin(BCD.Symbols), *E = std::end(BCD.Symbols);
collectRelocatedSymbols(Obj, Sec, SecAddress, SymAddress, SymSize, I, E);