mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
Added more clang-tidy checks
Improved GitHub Action to run clang-format as part of clang-tidy * Simplify clang-tidy workflow * Added modernize-use-using, modernize-redundant-void-arg, readability-static-accessed-through-instance * Add nolint for libecl typedefs
This commit is contained in:
@@ -110,8 +110,8 @@ public:
|
||||
void calculateCondensedTransmissibilities();
|
||||
|
||||
protected:
|
||||
typedef std::pair<CellAddress, std::map<CellAddress, double>> ConnectionTransmissibility;
|
||||
typedef std::map<CellAddress, std::map<CellAddress, double>> ConnectionTransmissibilities;
|
||||
using ConnectionTransmissibility = std::pair<CellAddress, std::map<CellAddress, double>>;
|
||||
using ConnectionTransmissibilities = std::map<CellAddress, std::map<CellAddress, double>>;
|
||||
|
||||
ConnectionTransmissibilities m_neighborTransmissibilities;
|
||||
ConnectionTransmissibilities m_condensedTransmissibilities;
|
||||
|
||||
@@ -2073,7 +2073,7 @@ double newtran( double cdarchy, double mult, double halfCellTrans, double neighb
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
typedef size_t ( *ResultIndexFunction )( const RigActiveCellInfo* activeCellinfo, size_t reservoirCellIndex );
|
||||
using ResultIndexFunction = size_t ( * )( const RigActiveCellInfo*, size_t );
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
@@ -2750,7 +2750,7 @@ void RigCaseCellResultsData::computeCompletionTypeForTimeStep( size_t timeStep )
|
||||
auto gridCalculation = dynamic_cast<RimGridCalculation*>( userCalculation );
|
||||
if ( gridCalculation && gridCalculation->outputEclipseCase() != eclipseCase ) continue;
|
||||
|
||||
QString generatedPropertyName = userCalculation->findLeftHandSide( userCalculation->expression() );
|
||||
QString generatedPropertyName = RimUserDefinedCalculation::findLeftHandSide( userCalculation->expression() );
|
||||
if ( generatedPropertyName == propertyName )
|
||||
{
|
||||
userCalculation->calculate();
|
||||
|
||||
@@ -252,7 +252,7 @@ void RigCellFaceGeometryTools::extractConnectionsForFace( const RigFault::FaultF
|
||||
size_t k;
|
||||
mainGrid->ijkFromCellIndexUnguarded( sourceReservoirCellIndex, &i, &j, &k );
|
||||
|
||||
mainGrid->neighborIJKAtCellFace( i, j, k, sourceCellFace, &ni, &nj, &nk );
|
||||
RigMainGrid::neighborIJKAtCellFace( i, j, k, sourceCellFace, &ni, &nj, &nk );
|
||||
|
||||
if ( mainGrid->isCellValid( ni, nj, nk ) )
|
||||
{
|
||||
|
||||
@@ -373,7 +373,7 @@ bool RigEclipseCaseData::findSharedSourceFace( cvf::StructGridInterface::FaceTyp
|
||||
cvf::StructGridInterface::FaceType sourceFace = static_cast<cvf::StructGridInterface::FaceType>( faceIdx );
|
||||
|
||||
size_t ni, nj, nk;
|
||||
grid->neighborIJKAtCellFace( i, j, k, sourceFace, &ni, &nj, &nk );
|
||||
RigGridBase::neighborIJKAtCellFace( i, j, k, sourceFace, &ni, &nj, &nk );
|
||||
|
||||
if ( grid->isCellValid( ni, nj, nk ) )
|
||||
{
|
||||
|
||||
@@ -167,7 +167,7 @@ void RigFault::computeFaultFacesFromCellRanges( const RigMainGrid* mainGrid )
|
||||
// size_t reservoirCellIndex = grid->reservoirCellIndex(gridLocalCellIndex);
|
||||
|
||||
size_t ni, nj, nk;
|
||||
mainGrid->neighborIJKAtCellFace( i, j, k, faceEnum, &ni, &nj, &nk );
|
||||
RigMainGrid::neighborIJKAtCellFace( i, j, k, faceEnum, &ni, &nj, &nk );
|
||||
if ( ni < mainGrid->cellCountI() && nj < mainGrid->cellCountJ() && nk < mainGrid->cellCountK() )
|
||||
{
|
||||
size_t gridLocalCellIndex = mainGrid->cellIndexFromIJK( i, j, k );
|
||||
|
||||
@@ -62,7 +62,7 @@ private:
|
||||
class RigFault : public cvf::Object
|
||||
{
|
||||
public:
|
||||
typedef std::tuple<size_t, size_t, size_t, cvf::StructGridInterface::FaceType> CellAndFace;
|
||||
using CellAndFace = std::tuple<size_t, size_t, size_t, cvf::StructGridInterface::FaceType>;
|
||||
|
||||
struct FaultFace
|
||||
{
|
||||
|
||||
@@ -47,7 +47,7 @@ public:
|
||||
PHASE_WAT = 0b100,
|
||||
};
|
||||
|
||||
typedef caf::AppEnum<PhaseSelection> PhaseSelectionEnum;
|
||||
using PhaseSelectionEnum = caf::AppEnum<PhaseSelection>;
|
||||
|
||||
RigFlowDiagResultAddress( const std::string& aVariableName, PhaseSelection phaseSelection, const std::set<std::string>& someSelectedTracerNames )
|
||||
: variableName( aVariableName )
|
||||
|
||||
@@ -49,7 +49,7 @@ public:
|
||||
CELLS_DRAINED,
|
||||
};
|
||||
|
||||
typedef caf::AppEnum<CellFilter> CellFilterEnum;
|
||||
using CellFilterEnum = caf::AppEnum<CellFilter>;
|
||||
|
||||
public:
|
||||
RigFlowDiagResults( RimFlowDiagSolution* flowSolution, size_t timeStepCount );
|
||||
|
||||
@@ -36,7 +36,7 @@ public:
|
||||
double solveStassiDalia( double* thetaOut = nullptr );
|
||||
|
||||
private:
|
||||
typedef double ( RigGeoMechBoreHoleStressCalculator::*MemberFunc )( double pw, double* thetaOut ) const;
|
||||
using MemberFunc = double ( RigGeoMechBoreHoleStressCalculator::* )( double, double* ) const;
|
||||
double solveBisection( double minPw, double maxPw, MemberFunc fn, double* thetaOut );
|
||||
double solveSecant( MemberFunc fn, double* thetaOut );
|
||||
double sigmaTMinOfMin( double wellPressure, double* thetaAtMin ) const;
|
||||
|
||||
@@ -45,7 +45,7 @@ RigGridBase::RigGridBase( RigMainGrid* mainGrid )
|
||||
}
|
||||
}
|
||||
|
||||
RigGridBase::~RigGridBase( void )
|
||||
RigGridBase::~RigGridBase()
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user