FreeCAD: Compiler warning fixes

This commit is contained in:
Chris Hennes
2025-03-12 23:16:43 -05:00
committed by Kacper Donat
parent b170b8e27c
commit 21c07cabc5
15 changed files with 32 additions and 24 deletions

View File

@@ -23,7 +23,7 @@ static std::string random_string(size_t length)
std::random_device rd;
std::mt19937 gen(rd());
std::uniform_int_distribution<> dis(0, digits.size() - 1);
std::uniform_int_distribution<> dis(0, static_cast<int>(digits.size()) - 1);
std::string result;
for (size_t i = 0; i < length; ++i) {

View File

@@ -114,7 +114,7 @@ TEST_F(FuzzyBooleanTest, testFailsTooSmallFuzzy)
double oldFuzzy = Part::FuzzyHelper::getBooleanFuzzy();
Part::FuzzyHelper::setBooleanFuzzy(0.01);
_fuse->execute();
EXPECT_FLOAT_EQ(Part::FuzzyHelper::getBooleanFuzzy(), 0.01);
EXPECT_DOUBLE_EQ(Part::FuzzyHelper::getBooleanFuzzy(), 0.01);
Part::FuzzyHelper::setBooleanFuzzy(oldFuzzy);
// Verify