ThreadCachedInt& operator-=(IntT inc) { increment(-inc); return *this; }
// pre-increment (we don't support post-increment)
ThreadCachedInt& operator++() { increment(1); return *this; }
- ThreadCachedInt& operator--() { increment(-1); return *this; }
+ ThreadCachedInt& operator--() {
+ increment(IntT(-1));
+ return *this;
+ }
// Thread-safe set function.
// This is a best effort implementation. In some edge cases, there could be
};
};
-}
+} // namespace folly