mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-21 12:55:31 +08:00
Fix floating point comparison
This commit is contained in:
@@ -333,7 +333,7 @@ namespace BlackMisc
|
||||
bool isEpsilon(double value) const
|
||||
{
|
||||
if (this->isNull()) return false;
|
||||
if (value == 0) return true;
|
||||
if (qFuzzyIsNull(value)) return true;
|
||||
return std::abs(value) <= this->m_data->m_epsilon;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user