forked from OSchip/llvm-project
[llvm-readobj] - Fix a warning.
This addresses post review comment for D92018. The warning was: ``` error: loop variable 'Note' is always a copy because the range of type 'iterator_range<llvm::object::ELFFile<llvm::object::ELFType<llvm::support::big, true> >::Elf_Note_Iterator>' (aka 'iterator_range<Elf_Note_Iterator_Impl<ELFType<(llvm::support::endianness)0U, true> > >') does not return a reference [-Werror,-Wrange-loop-analysis] for (const typename ELFT::Note &Note : Obj.notes(S, Err)) ```
This commit is contained in:
parent
14f2ad0e3c
commit
c3673ea65d
|
@ -5559,7 +5559,7 @@ static void printNotesHelper(
|
|||
StartNotesFn(expectedToOptional(Obj.getSectionName(S)), S.sh_offset,
|
||||
S.sh_size);
|
||||
Error Err = Error::success();
|
||||
for (const typename ELFT::Note &Note : Obj.notes(S, Err))
|
||||
for (const typename ELFT::Note Note : Obj.notes(S, Err))
|
||||
ProcessNoteFn(Note);
|
||||
if (Err)
|
||||
Dumper.reportUniqueWarning(
|
||||
|
|
Loading…
Reference in New Issue