[all-commits] [llvm/llvm-project] c3673e: [llvm-readobj] - Fix a warning.

Georgii Rymar via All-commits all-commits at lists.llvm.org
Wed Nov 25 23:24:59 PST 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: c3673ea65df576535c85397dfe36624bd09fe47b
      https://github.com/llvm/llvm-project/commit/c3673ea65df576535c85397dfe36624bd09fe47b
  Author: Georgii Rymar <grimar at accesssoftek.com>
  Date:   2020-11-26 (Thu, 26 Nov 2020)

  Changed paths:
    M llvm/tools/llvm-readobj/ELFDumper.cpp

  Log Message:
  -----------
  [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))
```




More information about the All-commits mailing list