[PATCH] D108124: Fix type in DenseMap<BitVector, *> to match V.size()
Renato Golin via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Aug 16 06:30:29 PDT 2021
rengolin added a comment.
In D108124#2946664 <https://reviews.llvm.org/D108124#2946664>, @serge-sans-paille wrote:
> SmallBitVector `size` method indeed return a `size_t`, but in a great show of consistency, `BitVector` doesn't (it returns `size_type` which aliases to `unsigned`)
Ugh. Worse, `SmallBitVector.size()` returns `size_t getSmallSize()` or `size_type getPointer()->size()`...
Ok, so we have two choices:
1. Change `SmallBitVector` to return `size_type`
2. Change `BitVector` to return `size_t`
I don't have enough information to pick, but given that the "smaller" version returns a potentially wider type, I think option 2 is best.
Either way, we also need to propagate the types across the users, so it won't be a simple patch as I wanted...
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D108124/new/
https://reviews.llvm.org/D108124
More information about the llvm-commits
mailing list