[PATCH] D24541: [LLVM] Fix some Clang-tidy readability-container-size-empty and Include What You Use warnings in headers; other minor fixes

Piotr Padlewski via llvm-commits llvm-commits at lists.llvm.org
Thu Sep 15 16:19:48 PDT 2016


Prazek added inline comments.

================
Comment at: include/llvm/CodeGen/LiveRangeEdit.h:158
@@ -151,1 +157,3 @@
+  unsigned size() const { return NewRegs.size() - FirstNew; }
+  bool empty() const { return NewRegs.size() == FirstNew; }
   unsigned get(unsigned idx) const { return NewRegs[idx+FirstNew]; }
----------------
mehdi_amini wrote:
> I don't really understand how it is more clear or better? I prefer the other version of empty() FWIW.
> 
+1


Repository:
  rL LLVM

https://reviews.llvm.org/D24541





More information about the llvm-commits mailing list