[PATCH] unsigned count() for ADT

Yaron Keren yaron.keren at gmail.com
Tue Jun 10 12:58:47 PDT 2014


Fixed first test per comment. The second test is trickier, comparing a bool to count() results in VC complaining:

..\..\..\lib\IR\Metadata.cpp(667): warning C4805: '==' : unsafe mix of type 'bool' and type

I modified it to read count() > 0, so the comparison will be between bools.

http://reviews.llvm.org/D4018

Files:
  include/llvm/ADT/BitVector.h
  include/llvm/ADT/DenseMap.h
  include/llvm/ADT/DenseSet.h
  include/llvm/ADT/MapVector.h
  include/llvm/ADT/ScopedHashTable.h
  include/llvm/ADT/SmallBitVector.h
  include/llvm/ADT/SmallPtrSet.h
  include/llvm/ADT/SmallSet.h
  include/llvm/ADT/SparseBitVector.h
  include/llvm/ADT/SparseMultiSet.h
  include/llvm/ADT/SparseSet.h
  include/llvm/IR/ValueMap.h
  lib/CodeGen/AsmPrinter/WinCodeViewLineTables.cpp
  lib/IR/Metadata.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D4018.10297.patch
Type: text/x-patch
Size: 11947 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20140610/d5153c35/attachment.bin>


More information about the llvm-commits mailing list