From b7758aa7061dca05337a6bf6dab3b99d3f4c3215 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Atgeirr=20Fl=C3=B8=20Rasmussen?= Date: Thu, 22 Sep 2022 09:32:17 +0200 Subject: [PATCH] Use std::array rather than C arrays. --- ebos/eclfluxmodule.hh | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/ebos/eclfluxmodule.hh b/ebos/eclfluxmodule.hh index 8f1c013cb..fe8908ed1 100644 --- a/ebos/eclfluxmodule.hh +++ b/ebos/eclfluxmodule.hh @@ -43,6 +43,8 @@ #include #include +#include + namespace Opm { template @@ -212,8 +214,8 @@ protected: public: - static void volumeAndPhasePressureDifferences(short (&upIdx)[numPhases], - short (&dnIdx)[numPhases], + static void volumeAndPhasePressureDifferences(std::array& upIdx, + std::array& dnIdx, Evaluation (&volumeFlux)[numPhases], Evaluation (&pressureDifferences)[numPhases], const ElementContext& elemCtx, @@ -449,8 +451,8 @@ public: const double faceArea, const double zEx, const FluidState& exFluidState, - short (&upIdx)[numPhases], - short (&dnIdx)[numPhases], + std::array& upIdx, + std::array& dnIdx, EvaluationContainer& volumeFlux, EvaluationContainer& pressureDifference) { @@ -572,9 +574,9 @@ private: Evaluation pressureDifference_[numPhases]; // the local indices of the interior and exterior degrees of freedom - short upIdx_[numPhases]; - short dnIdx_[numPhases]; -}; + std::array upIdx_; + std::array dnIdx_; + }; } // namespace Opm