mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-30 02:31:44 +00:00
Update for C++17 and fix MSVC warnings (#1694)
* Update MSVC arguments * Fix json allocator * Fix simulation diamond * Bump gtest * Remove empty varargs in unit tests * Replace test case with test suite * Remove deprecation warning in optional * Remove need for NOMIXMAX to be defined in wpilib headers
This commit is contained in:
committed by
Peter Johnson
parent
fb1239a2ad
commit
221011494d
@@ -352,7 +352,7 @@ protected:
|
||||
return 0;
|
||||
// +1 is required because of the strict equality.
|
||||
// For example if NumEntries is 48, we need to return 401.
|
||||
return NextPowerOf2(NumEntries * 4 / 3 + 1);
|
||||
return static_cast<unsigned>(NextPowerOf2(NumEntries * 4 / 3 + 1));
|
||||
}
|
||||
|
||||
void moveFromOldBuckets(BucketT *OldBucketsBegin, BucketT *OldBucketsEnd) {
|
||||
@@ -777,7 +777,7 @@ public:
|
||||
// Reduce the number of buckets.
|
||||
unsigned NewNumBuckets = 0;
|
||||
if (OldNumEntries)
|
||||
NewNumBuckets = std::max(64, 1 << (Log2_32_Ceil(OldNumEntries) + 1));
|
||||
NewNumBuckets = (std::max)(64, 1 << (Log2_32_Ceil(OldNumEntries) + 1));
|
||||
if (NewNumBuckets == NumBuckets) {
|
||||
this->BaseT::initEmpty();
|
||||
return;
|
||||
|
||||
Reference in New Issue
Block a user