Add readability-simplify-boolean-expr

* Add readability-simplify-boolean-expr
* Fixes based on review
This commit is contained in:
Magne Sjaastad
2023-06-26 13:12:41 +02:00
committed by GitHub
parent 34d83efaed
commit 59ca0b943c
116 changed files with 179 additions and 635 deletions

View File

@@ -59,9 +59,7 @@ bool RimCellFilterInterval::isIncluded( size_t val ) const
size_t tmp = val - m_minIncludeVal;
if ( m_valid && ( tmp % m_step == 0 ) ) return true;
return false;
return m_valid && ( tmp % m_step == 0 );
}
//--------------------------------------------------------------------------------------------------

View File

@@ -134,12 +134,7 @@ void RimEclipsePropertyFilter::rangeValues( double* lower, double* upper ) const
//--------------------------------------------------------------------------------------------------
bool RimEclipsePropertyFilter::isCategorySelectionActive() const
{
if ( m_resultDefinition->hasCategoryResult() && m_useCategorySelection )
{
return true;
}
return false;
return m_resultDefinition->hasCategoryResult() && m_useCategorySelection;
}
//--------------------------------------------------------------------------------------------------

View File

@@ -213,12 +213,7 @@ void RimGeoMechPropertyFilter::updateActiveState()
//--------------------------------------------------------------------------------------------------
bool RimGeoMechPropertyFilter::isActiveAndHasResult()
{
if ( this->isActive() && this->resultDefinition->hasResult() )
{
return true;
}
return false;
return this->isActive() && this->resultDefinition->hasResult();
}
//--------------------------------------------------------------------------------------------------