Swap a few APIs to reduce sign and implicit truncations required to work with it
[folly.git] / folly / AtomicHashMap.h
index ef27f860df41229eb586e63ea7961783ceedcd93..70d71491a4499231f3de70377da3bf31088645a1 100644 (file)
@@ -448,7 +448,7 @@ typedef AtomicHashArray<KeyT, ValueT, HashFcn, EqualFcn,
   std::atomic<SubMap*> subMaps_[kNumSubMaps_];
   std::atomic<uint32_t> numMapsAllocated_;
 
-  inline bool tryLockMap(int idx) {
+  inline bool tryLockMap(unsigned int idx) {
     SubMap* val = nullptr;
     return subMaps_[idx].compare_exchange_strong(val, (SubMap*)kLockedPtr_,
       std::memory_order_acquire);