mirror of
https://github.com/OPM/opm-simulators.git
synced 2024-12-30 11:06:55 -06:00
change the order of OPM_UNUSED and variable name
it seems like some compilers (GCC 4.9.2?) are picky about this and require ```c++ TypeName VariableName __attribute__ ((__unused__)) ```
This commit is contained in:
parent
0c8355d2ad
commit
61c501a31d
@ -63,42 +63,42 @@ public:
|
||||
{ }
|
||||
|
||||
template <bool prepareValues = true, bool prepareGradients = true>
|
||||
void prepare(const ElementContext& OPM_UNUSED elemCtx, unsigned OPM_UNUSED timeIdx)
|
||||
void prepare(const ElementContext& elemCtx OPM_UNUSED, unsigned timeIdx OPM_UNUSED)
|
||||
{ }
|
||||
|
||||
template <class QuantityCallback, class QuantityType = Scalar>
|
||||
QuantityType calculateValue(const ElementContext& OPM_UNUSED elemCtx,
|
||||
unsigned OPM_UNUSED fapIdx,
|
||||
const QuantityCallback& OPM_UNUSED quantityCallback) const
|
||||
QuantityType calculateValue(const ElementContext& elemCtx OPM_UNUSED,
|
||||
unsigned fapIdx OPM_UNUSED,
|
||||
const QuantityCallback& quantityCallback OPM_UNUSED) const
|
||||
{
|
||||
OPM_THROW(std::logic_error,
|
||||
"Generic values are not supported by the ECL black-oil simulator");
|
||||
}
|
||||
|
||||
template <class QuantityCallback>
|
||||
void calculateGradient(DimVector& OPM_UNUSED quantityGrad,
|
||||
const ElementContext& OPM_UNUSED elemCtx,
|
||||
unsigned OPM_UNUSED fapIdx,
|
||||
const QuantityCallback& OPM_UNUSED quantityCallback) const
|
||||
void calculateGradient(DimVector& quantityGrad OPM_UNUSED,
|
||||
const ElementContext& elemCtx OPM_UNUSED,
|
||||
unsigned fapIdx OPM_UNUSED,
|
||||
const QuantityCallback& quantityCallback OPM_UNUSED) const
|
||||
{
|
||||
OPM_THROW(std::logic_error,
|
||||
"Generic gradients are not supported by the ECL black-oil simulator");
|
||||
}
|
||||
|
||||
template <class QuantityCallback>
|
||||
Scalar calculateBoundaryValue(const ElementContext& OPM_UNUSED elemCtx,
|
||||
unsigned OPM_UNUSED fapIdx,
|
||||
const QuantityCallback& OPM_UNUSED quantityCallback)
|
||||
Scalar calculateBoundaryValue(const ElementContext& elemCtx OPM_UNUSED,
|
||||
unsigned fapIdx OPM_UNUSED,
|
||||
const QuantityCallback& quantityCallback OPM_UNUSED)
|
||||
{
|
||||
OPM_THROW(std::logic_error,
|
||||
"Generic boundary values are not supported by the ECL black-oil simulator");
|
||||
}
|
||||
|
||||
template <class QuantityCallback>
|
||||
void calculateBoundaryGradient(DimVector& OPM_UNUSED quantityGrad,
|
||||
const ElementContext& OPM_UNUSED elemCtx,
|
||||
unsigned OPM_UNUSED fapIdx,
|
||||
const QuantityCallback& OPM_UNUSED quantityCallback) const
|
||||
void calculateBoundaryGradient(DimVector& quantityGrad OPM_UNUSED,
|
||||
const ElementContext& elemCtx OPM_UNUSED,
|
||||
unsigned fapIdx OPM_UNUSED,
|
||||
const QuantityCallback& quantityCallback OPM_UNUSED) const
|
||||
{
|
||||
OPM_THROW(std::logic_error,
|
||||
"Generic boundary gradients are not supported by the ECL black-oil simulator");
|
||||
|
@ -91,7 +91,7 @@ class EclTransIntensiveQuantities
|
||||
{
|
||||
typedef typename GET_PROP_TYPE(TypeTag, ElementContext) ElementContext;
|
||||
protected:
|
||||
void update_(const ElementContext& OPM_UNUSED elemCtx, unsigned OPM_UNUSED dofIdx, unsigned OPM_UNUSED timeIdx)
|
||||
void update_(const ElementContext& elemCtx OPM_UNUSED, unsigned dofIdx OPM_UNUSED, unsigned timeIdx OPM_UNUSED)
|
||||
{ }
|
||||
};
|
||||
|
||||
@ -139,7 +139,7 @@ public:
|
||||
*
|
||||
* \param phaseIdx The index of the fluid phase
|
||||
*/
|
||||
const EvalDimVector& potentialGrad(unsigned OPM_UNUSED phaseIdx) const
|
||||
const EvalDimVector& potentialGrad(unsigned phaseIdx OPM_UNUSED) const
|
||||
{
|
||||
OPM_THROW(Opm::NotImplemented,
|
||||
"The ECL transmissibility module does not provide explicit potential gradients");
|
||||
@ -160,7 +160,7 @@ public:
|
||||
*
|
||||
* \param phaseIdx The index of the fluid phase
|
||||
*/
|
||||
const EvalDimVector& filterVelocity(unsigned OPM_UNUSED phaseIdx) const
|
||||
const EvalDimVector& filterVelocity(unsigned phaseIdx OPM_UNUSED) const
|
||||
{
|
||||
OPM_THROW(Opm::NotImplemented,
|
||||
"The ECL transmissibility module does not provide explicit filter velocities");
|
||||
@ -348,7 +348,7 @@ protected:
|
||||
/*!
|
||||
* \brief Update the volumetric fluxes for all fluid phases on the interior faces of the context
|
||||
*/
|
||||
void calculateFluxes_(const ElementContext& OPM_UNUSED elemCtx, unsigned OPM_UNUSED scvfIdx, unsigned OPM_UNUSED timeIdx)
|
||||
void calculateFluxes_(const ElementContext& elemCtx OPM_UNUSED, unsigned scvfIdx OPM_UNUSED, unsigned timeIdx OPM_UNUSED)
|
||||
{ }
|
||||
|
||||
// transmissibility [m^3 s]
|
||||
|
@ -136,7 +136,7 @@ class EclPeacemanWell : public BaseAuxiliaryModule<TypeTag>
|
||||
|
||||
// retrieve the solution dependent quantities that are only updated at the
|
||||
// beginning of a time step from the IntensiveQuantities of the model
|
||||
void updateBeginTimestep(const IntensiveQuantities& OPM_UNUSED intQuants)
|
||||
void updateBeginTimestep(const IntensiveQuantities& intQuants OPM_UNUSED)
|
||||
{}
|
||||
|
||||
// retrieve the solution dependent quantities from the IntensiveQuantities of the
|
||||
|
@ -775,9 +775,9 @@ public:
|
||||
*/
|
||||
template <class Context>
|
||||
void boundary(BoundaryRateVector& values,
|
||||
const Context& OPM_UNUSED context,
|
||||
unsigned OPM_UNUSED spaceIdx,
|
||||
unsigned OPM_UNUSED timeIdx) const
|
||||
const Context& context OPM_UNUSED,
|
||||
unsigned spaceIdx OPM_UNUSED,
|
||||
unsigned timeIdx OPM_UNUSED) const
|
||||
{ values.setNoFlow(); }
|
||||
|
||||
/*!
|
||||
|
@ -542,7 +542,7 @@ public:
|
||||
* to the hard disk.
|
||||
*/
|
||||
template <class Restarter>
|
||||
void serialize(Restarter& OPM_UNUSED res)
|
||||
void serialize(Restarter& res OPM_UNUSED)
|
||||
{
|
||||
/* do nothing: Everything which we need here is provided by the deck->.. */
|
||||
}
|
||||
@ -554,7 +554,7 @@ public:
|
||||
* It is the inverse of the serialize() method.
|
||||
*/
|
||||
template <class Restarter>
|
||||
void deserialize(Restarter& OPM_UNUSED res)
|
||||
void deserialize(Restarter& res OPM_UNUSED)
|
||||
{
|
||||
// initialize the wells for the current episode
|
||||
beginEpisode(simulator_.gridManager().eclState(), /*wasRestarted=*/true);
|
||||
@ -604,7 +604,7 @@ protected:
|
||||
reportStepIdx);
|
||||
}
|
||||
|
||||
void updateWellTopology_(unsigned OPM_UNUSED reportStepIdx,
|
||||
void updateWellTopology_(unsigned reportStepIdx OPM_UNUSED,
|
||||
const WellCompletionsMap& wellCompletions,
|
||||
std::vector<bool>& gridDofIsPenetrated) const
|
||||
{
|
||||
@ -664,7 +664,7 @@ protected:
|
||||
}
|
||||
}
|
||||
|
||||
void computeWellCompletionsMap_(unsigned OPM_UNUSED reportStepIdx, WellCompletionsMap& cartesianIdxToCompletionMap)
|
||||
void computeWellCompletionsMap_(unsigned reportStepIdx OPM_UNUSED, WellCompletionsMap& cartesianIdxToCompletionMap)
|
||||
{
|
||||
const auto& eclState = simulator_.gridManager().eclState();
|
||||
const auto& deckSchedule = eclState.getSchedule();
|
||||
|
@ -168,7 +168,7 @@ public:
|
||||
/*!
|
||||
* \brief Called whenever a new time step must be written.
|
||||
*/
|
||||
void beginWrite(double OPM_UNUSED t)
|
||||
void beginWrite(double t OPM_UNUSED)
|
||||
{
|
||||
if (enableEclOutput_() && reportStepIdx_ == 0 && collectToIORank_.isIORank() )
|
||||
EclWriterHelper<TypeTag, GridManager>::writeHeaders_(*this);
|
||||
@ -180,7 +180,7 @@ public:
|
||||
* For the EclWriter, this method is a no-op which throws a
|
||||
* std::logic_error exception
|
||||
*/
|
||||
void attachScalarVertexData(ScalarBuffer& OPM_UNUSED buf, std::string OPM_UNUSED name)
|
||||
void attachScalarVertexData(ScalarBuffer& buf OPM_UNUSED, std::string name OPM_UNUSED)
|
||||
{
|
||||
OPM_THROW(std::logic_error,
|
||||
"The EclWriter can only write element based quantities!");
|
||||
@ -192,7 +192,7 @@ public:
|
||||
* For the EclWriter, this method is a no-op which throws a
|
||||
* std::logic_error exception
|
||||
*/
|
||||
void attachVectorVertexData(VectorBuffer& OPM_UNUSED buf, std::string OPM_UNUSED name)
|
||||
void attachVectorVertexData(VectorBuffer& buf OPM_UNUSED, std::string name OPM_UNUSED)
|
||||
{
|
||||
OPM_THROW(std::logic_error,
|
||||
"The EclWriter can only write element based quantities!");
|
||||
@ -201,7 +201,7 @@ public:
|
||||
/*
|
||||
* \brief Add a vertex-centered tensor field to the output.
|
||||
*/
|
||||
void attachTensorVertexData(TensorBuffer& OPM_UNUSED buf, std::string OPM_UNUSED name)
|
||||
void attachTensorVertexData(TensorBuffer& buf OPM_UNUSED, std::string name OPM_UNUSED)
|
||||
{
|
||||
OPM_THROW(std::logic_error,
|
||||
"The EclWriter can only write element based quantities!");
|
||||
@ -225,7 +225,7 @@ public:
|
||||
* For the EclWriter, this method is a no-op which throws a
|
||||
* std::logic_error exception
|
||||
*/
|
||||
void attachVectorElementData(VectorBuffer& OPM_UNUSED buf, std::string OPM_UNUSED name)
|
||||
void attachVectorElementData(VectorBuffer& buf OPM_UNUSED, std::string name OPM_UNUSED)
|
||||
{
|
||||
OPM_THROW(std::logic_error,
|
||||
"Currently, the EclWriter can only write scalar quantities!");
|
||||
@ -234,7 +234,7 @@ public:
|
||||
/*
|
||||
* \brief Add a element-centered tensor field to the output.
|
||||
*/
|
||||
void attachTensorElementData(TensorBuffer& OPM_UNUSED buf, std::string OPM_UNUSED name)
|
||||
void attachTensorElementData(TensorBuffer& buf OPM_UNUSED, std::string name OPM_UNUSED)
|
||||
{
|
||||
OPM_THROW(std::logic_error,
|
||||
"Currently, the EclWriter can only write scalar quantities!");
|
||||
|
Loading…
Reference in New Issue
Block a user