diff --git a/src/EnergyPlus/AirflowNetwork/include/AirflowNetwork/Elements.hpp b/src/EnergyPlus/AirflowNetwork/include/AirflowNetwork/Elements.hpp index b6d27baaa6d..170fa08ecce 100644 --- a/src/EnergyPlus/AirflowNetwork/include/AirflowNetwork/Elements.hpp +++ b/src/EnergyPlus/AirflowNetwork/include/AirflowNetwork/Elements.hpp @@ -449,15 +449,15 @@ namespace AirflowNetwork { ) = 0; // Make this abstract once all the classes implement it - virtual int calculate(EnergyPlusData & EP_UNUSED(state), - const Real64 EP_UNUSED(PDROP), // Total pressure drop across a component (P1 - P2) [Pa] - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &EP_UNUSED(propN), // Node 1 properties - const AirProperties &EP_UNUSED(propM), // Node 2 properties - std::array &EP_UNUSED(F), // Airflow through the component [kg/s] - std::array &EP_UNUSED(DF) // Partial derivative: DF/DP - ) + virtual int calculate([[maybe_unused]] EnergyPlusData &state, + [[maybe_unused]] const Real64 PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + [[maybe_unused]] const AirProperties &propN, // Node 1 properties + [[maybe_unused]] const AirProperties &propM, // Node 2 properties + [[maybe_unused]] std::array &F, // Airflow through the component [kg/s] + [[maybe_unused]] std::array &DF // Partial derivative: DF/DP + ) { return 1; } @@ -510,16 +510,16 @@ namespace AirflowNetwork { { } - int calculate(EnergyPlusData & EP_UNUSED(state), - bool const LFLAG, // Initialization flag.If = 1, use laminar relationship - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - int const i, // Linkage number - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + int calculate([[maybe_unused]] EnergyPlusData &state, + bool const LFLAG, // Initialization flag.If = 1, use laminar relationship + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + int const i, // Linkage number + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ); virtual ComponentType type() @@ -543,15 +543,15 @@ namespace AirflowNetwork { } int calculate(EnergyPlusData &state, - bool const LFLAG, // Initialization flag.If = 1, use laminar relationship - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - int const i, // Linkage number - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + bool const LFLAG, // Initialization flag.If = 1, use laminar relationship + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + int const i, // Linkage number + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ); virtual ComponentType type() @@ -574,15 +574,15 @@ namespace AirflowNetwork { } int calculate(EnergyPlusData &state, - bool const LFLAG, // Initialization flag.If = 1, use laminar relationship - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - int const i, // Linkage number - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + bool const LFLAG, // Initialization flag.If = 1, use laminar relationship + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + int const i, // Linkage number + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ); virtual ComponentType type() @@ -626,15 +626,15 @@ namespace AirflowNetwork { } int calculate(EnergyPlusData &state, - bool const LFLAG, // Initialization flag.If = 1, use laminar relationship - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - int const i, // Linkage number - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + bool const LFLAG, // Initialization flag.If = 1, use laminar relationship + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + int const i, // Linkage number + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ); virtual int calculate(EnergyPlusData &state, @@ -668,26 +668,26 @@ namespace AirflowNetwork { { } - int calculate(EnergyPlusData & EP_UNUSED(state), - bool const LFLAG, // Initialization flag.If = 1, use laminar relationship - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - int const EP_UNUSED(i), // Linkage number - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + int calculate([[maybe_unused]] EnergyPlusData &state, + bool const LFLAG, // Initialization flag.If = 1, use laminar relationship + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + [[maybe_unused]] int const i, // Linkage number + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ); - int calculate(EnergyPlusData & EP_UNUSED(state), - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + int calculate([[maybe_unused]] EnergyPlusData &state, + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ); virtual ComponentType type() @@ -719,25 +719,25 @@ namespace AirflowNetwork { } int calculate(EnergyPlusData &state, - bool const LFLAG, // Initialization flag.If = 1, use laminar relationship - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - int const i, // Linkage number - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + bool const LFLAG, // Initialization flag.If = 1, use laminar relationship + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + int const i, // Linkage number + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ); int calculate(EnergyPlusData &state, - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 control, // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + [[maybe_unused]] const Real64 multiplier, // Element multiplier + const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ); virtual ComponentType type() @@ -853,25 +853,25 @@ namespace AirflowNetwork { } int calculate(EnergyPlusData &state, - bool const LFLAG, // Initialization flag.If = 1, use laminar relationship - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - int const i, // Linkage number - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + bool const LFLAG, // Initialization flag.If = 1, use laminar relationship + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + int const i, // Linkage number + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ); int calculate(EnergyPlusData &state, - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ); virtual ComponentType type() @@ -893,26 +893,26 @@ namespace AirflowNetwork { { } - int calculate(EnergyPlusData & EP_UNUSED(state), - bool const LFLAG, // Initialization flag.If = 1, use laminar relationship - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - int const EP_UNUSED(i), // Linkage number - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + int calculate([[maybe_unused]] EnergyPlusData &state, + bool const LFLAG, // Initialization flag.If = 1, use laminar relationship + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + [[maybe_unused]] int const i, // Linkage number + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ); - int calculate(EnergyPlusData & EP_UNUSED(state), - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + int calculate([[maybe_unused]] EnergyPlusData &state, + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ); virtual ComponentType type() @@ -951,26 +951,26 @@ namespace AirflowNetwork { { } - int calculate(EnergyPlusData & EP_UNUSED(state), - bool const LFLAG, // Initialization flag.If = 1, use laminar relationship - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - int const EP_UNUSED(i), // Linkage number - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + int calculate([[maybe_unused]] EnergyPlusData &state, + bool const LFLAG, // Initialization flag.If = 1, use laminar relationship + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + [[maybe_unused]] int const i, // Linkage number + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ); - int calculate(EnergyPlusData & EP_UNUSED(state), - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + int calculate([[maybe_unused]] EnergyPlusData &state, + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ); virtual ComponentType type() @@ -998,26 +998,26 @@ namespace AirflowNetwork { { } - int calculate(EnergyPlusData & EP_UNUSED(state), - bool const LFLAG, // Initialization flag.If = 1, use laminar relationship - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - int const i, // Linkage number - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + int calculate([[maybe_unused]] EnergyPlusData &state, + bool const LFLAG, // Initialization flag.If = 1, use laminar relationship + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + int const i, // Linkage number + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ); - int calculate(EnergyPlusData & EP_UNUSED(state), - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 control, // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + int calculate([[maybe_unused]] EnergyPlusData &state, + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + [[maybe_unused]] const Real64 multiplier, // Element multiplier + const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ); virtual ComponentType type() @@ -1046,15 +1046,15 @@ namespace AirflowNetwork { } int calculate(EnergyPlusData &state, - bool const LFLAG, // Initialization flag.If = 1, use laminar relationship - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - int const i, // Linkage number - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + bool const LFLAG, // Initialization flag.If = 1, use laminar relationship + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + int const i, // Linkage number + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ); virtual ComponentType type() @@ -1081,26 +1081,26 @@ namespace AirflowNetwork { { } - int calculate(EnergyPlusData & EP_UNUSED(state), - bool const LFLAG, // Initialization flag.If = 1, use laminar relationship - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - int const i, // Linkage number - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + int calculate([[maybe_unused]] EnergyPlusData &state, + bool const LFLAG, // Initialization flag.If = 1, use laminar relationship + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + int const i, // Linkage number + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ); int calculate(EnergyPlusData &state, - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 control, // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + [[maybe_unused]] const Real64 multiplier, // Element multiplier + const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ); virtual ComponentType type() @@ -1122,26 +1122,26 @@ namespace AirflowNetwork { { } - int calculate(EnergyPlusData & EP_UNUSED(state), - bool const LFLAG, // Initialization flag.If = 1, use laminar relationship - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - int const i, // Linkage number - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + int calculate([[maybe_unused]] EnergyPlusData &state, + bool const LFLAG, // Initialization flag.If = 1, use laminar relationship + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + int const i, // Linkage number + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ); - int calculate(EnergyPlusData & EP_UNUSED(state), - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + int calculate([[maybe_unused]] EnergyPlusData &state, + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ); virtual ComponentType type() @@ -1163,26 +1163,26 @@ namespace AirflowNetwork { { } - int calculate(EnergyPlusData & EP_UNUSED(state), - bool const LFLAG, // Initialization flag.If = 1, use laminar relationship - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - int const EP_UNUSED(i), // Linkage number - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + int calculate([[maybe_unused]] EnergyPlusData &state, + bool const LFLAG, // Initialization flag.If = 1, use laminar relationship + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + [[maybe_unused]] int const i, // Linkage number + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ); - int calculate(EnergyPlusData & EP_UNUSED(state), - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + int calculate([[maybe_unused]] EnergyPlusData &state, + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ); virtual ComponentType type() @@ -1206,16 +1206,16 @@ namespace AirflowNetwork { { } - int calculate(EnergyPlusData & EP_UNUSED(state), - bool const LFLAG, // Initialization flag.If = 1, use laminar relationship - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - int const i, // Linkage number - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + int calculate([[maybe_unused]] EnergyPlusData &state, + bool const LFLAG, // Initialization flag.If = 1, use laminar relationship + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + int const i, // Linkage number + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ); virtual ComponentType type() @@ -1235,16 +1235,16 @@ namespace AirflowNetwork { { } - int calculate(EnergyPlusData & EP_UNUSED(state), - bool const LFLAG, // Initialization flag.If = 1, use laminar relationship - const Real64 PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - int const i, // Linkage number - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + int calculate([[maybe_unused]] EnergyPlusData &state, + bool const LFLAG, // Initialization flag.If = 1, use laminar relationship + const Real64 PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + int const i, // Linkage number + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ); virtual ComponentType type() @@ -1381,15 +1381,15 @@ namespace AirflowNetwork { } virtual int calculate(EnergyPlusData &state, - bool const LFLAG, // Initialization flag.If = 1, use laminar relationship - const Real64 PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - int const i, // Linkage number - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + bool const LFLAG, // Initialization flag.If = 1, use laminar relationship + const Real64 PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + int const i, // Linkage number + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ); virtual ComponentType type() @@ -1407,15 +1407,15 @@ namespace AirflowNetwork { } virtual int calculate(EnergyPlusData &state, - bool const LFLAG, // Initialization flag.If = 1, use laminar relationship - const Real64 PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - int const i, // Linkage number - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + bool const LFLAG, // Initialization flag.If = 1, use laminar relationship + const Real64 PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + int const i, // Linkage number + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ); virtual ComponentType type() diff --git a/src/EnergyPlus/AirflowNetwork/src/Elements.cpp b/src/EnergyPlus/AirflowNetwork/src/Elements.cpp index 0c6eb547ff4..24088b43121 100644 --- a/src/EnergyPlus/AirflowNetwork/src/Elements.cpp +++ b/src/EnergyPlus/AirflowNetwork/src/Elements.cpp @@ -234,16 +234,16 @@ namespace AirflowNetwork { return x * x; } - int Duct::calculate(EnergyPlusData & EP_UNUSED(state), - bool const LFLAG, // Initialization flag.If = 1, use laminar relationship - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - int const EP_UNUSED(i), // Linkage number - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + int Duct::calculate([[maybe_unused]] EnergyPlusData &state, + bool const LFLAG, // Initialization flag.If = 1, use laminar relationship + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + [[maybe_unused]] int const i, // Linkage number + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ) { @@ -388,14 +388,14 @@ namespace AirflowNetwork { return 1; } - int Duct::calculate(EnergyPlusData & EP_UNUSED(state), - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + int Duct::calculate([[maybe_unused]] EnergyPlusData &state, + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ) { @@ -530,15 +530,15 @@ namespace AirflowNetwork { } int SurfaceCrack::calculate(EnergyPlusData &state, - bool const LFLAG, // Initialization flag.If = 1, use laminar relationship - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - int const i, // Linkage number - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + bool const LFLAG, // Initialization flag.If = 1, use laminar relationship + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + int const i, // Linkage number + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ) { // SUBROUTINE INFORMATION: @@ -752,17 +752,16 @@ namespace AirflowNetwork { return 1; } - int DuctLeak::calculate(EnergyPlusData &state, - bool const LFLAG, // Initialization flag.If = 1, use laminar relationship - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - int const EP_UNUSED(i), // Linkage number - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + bool const LFLAG, // Initialization flag.If = 1, use laminar relationship + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + [[maybe_unused]] int const i, // Linkage number + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ) { // SUBROUTINE INFORMATION: @@ -850,13 +849,14 @@ namespace AirflowNetwork { return 1; } - int DuctLeak::calculate(EnergyPlusData &state, Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + int DuctLeak::calculate(EnergyPlusData &state, + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ) { // SUBROUTINE INFORMATION: @@ -933,15 +933,15 @@ namespace AirflowNetwork { } int ConstantVolumeFan::calculate(EnergyPlusData &state, - bool const LFLAG, // Initialization flag.If = 1, use laminar relationship - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - int const i, // Linkage number - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + bool const LFLAG, // Initialization flag.If = 1, use laminar relationship + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + int const i, // Linkage number + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ) { @@ -1044,15 +1044,15 @@ namespace AirflowNetwork { } int DetailedFan::calculate(EnergyPlusData &state, - bool const LFLAG, // Initialization flag.If = 1, use laminar relationship - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - int const i, // Linkage number - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + bool const LFLAG, // Initialization flag.If = 1, use laminar relationship + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + int const i, // Linkage number + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ) { @@ -1174,13 +1174,14 @@ namespace AirflowNetwork { return 1; } - int DetailedFan::calculate(EnergyPlusData &state, Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 control, // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + int DetailedFan::calculate(EnergyPlusData &state, + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + [[maybe_unused]] const Real64 multiplier, // Element multiplier + const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ) { @@ -1302,17 +1303,16 @@ namespace AirflowNetwork { return 1; } - - int Damper::calculate(EnergyPlusData & EP_UNUSED(state), - bool const LFLAG, // Initialization flag.If = 1, use laminar relationship - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - int const i, // Linkage number - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + int Damper::calculate([[maybe_unused]] EnergyPlusData &state, + bool const LFLAG, // Initialization flag.If = 1, use laminar relationship + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + int const i, // Linkage number + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ) { @@ -1368,14 +1368,14 @@ namespace AirflowNetwork { return 1; } - int Damper::calculate(EnergyPlusData & EP_UNUSED(state), - const Real64 PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 control, // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + int Damper::calculate([[maybe_unused]] EnergyPlusData &state, + const Real64 PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + [[maybe_unused]] const Real64 multiplier, // Element multiplier + const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ) { @@ -1431,16 +1431,16 @@ namespace AirflowNetwork { return 1; } - int EffectiveLeakageRatio::calculate(EnergyPlusData & EP_UNUSED(state), - bool const LFLAG, // Initialization flag.If = 1, use laminar relationship - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - int const EP_UNUSED(i), // Linkage number - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + int EffectiveLeakageRatio::calculate([[maybe_unused]] EnergyPlusData &state, + bool const LFLAG, // Initialization flag.If = 1, use laminar relationship + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + [[maybe_unused]] int const i, // Linkage number + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ) { @@ -1520,14 +1520,14 @@ namespace AirflowNetwork { return 1; } - int EffectiveLeakageRatio::calculate(EnergyPlusData & EP_UNUSED(state), - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + int EffectiveLeakageRatio::calculate([[maybe_unused]] EnergyPlusData &state, + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ) { @@ -1598,15 +1598,15 @@ namespace AirflowNetwork { } int DetailedOpening::calculate(EnergyPlusData &state, - bool const EP_UNUSED(LFLAG), // Initialization flag.If = 1, use laminar relationship - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - int const IL, // Linkage number - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &EP_UNUSED(propN), // Node 1 properties - const AirProperties &EP_UNUSED(propM), // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + [[maybe_unused]] bool const LFLAG, // Initialization flag.If = 1, use laminar relationship + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + int const IL, // Linkage number + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + [[maybe_unused]] const AirProperties &propN, // Node 1 properties + [[maybe_unused]] const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ) { @@ -2061,15 +2061,15 @@ namespace AirflowNetwork { } int SimpleOpening::calculate(EnergyPlusData &state, - bool const LFLAG, // Initialization flag.If = 1, use laminar relationship - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - int const i, // Linkage number - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + bool const LFLAG, // Initialization flag.If = 1, use laminar relationship + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + int const i, // Linkage number + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ) { @@ -2205,16 +2205,16 @@ namespace AirflowNetwork { return NF; } - int ConstantPressureDrop::calculate(EnergyPlusData & EP_UNUSED(state), - bool const EP_UNUSED(LFLAG), // Initialization flag.If = 1, use laminar relationship - const Real64 PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - int const i, // Linkage number - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &EP_UNUSED(propM), // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + int ConstantPressureDrop::calculate([[maybe_unused]] EnergyPlusData &state, + [[maybe_unused]] bool const LFLAG, // Initialization flag.If = 1, use laminar relationship + const Real64 PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + int const i, // Linkage number + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + [[maybe_unused]] const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ) { @@ -2264,16 +2264,16 @@ namespace AirflowNetwork { return 1; } - int EffectiveLeakageArea::calculate(EnergyPlusData & EP_UNUSED(state), - bool const LFLAG, // Initialization flag.If = 1, use laminar relationship - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - int const EP_UNUSED(i), // Linkage number - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + int EffectiveLeakageArea::calculate([[maybe_unused]] EnergyPlusData &state, + bool const LFLAG, // Initialization flag.If = 1, use laminar relationship + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + [[maybe_unused]] int const i, // Linkage number + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ) { @@ -2356,14 +2356,14 @@ namespace AirflowNetwork { return 1; } - int EffectiveLeakageArea::calculate(EnergyPlusData & EP_UNUSED(state), - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + int EffectiveLeakageArea::calculate([[maybe_unused]] EnergyPlusData &state, + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ) { @@ -2437,16 +2437,16 @@ namespace AirflowNetwork { return 1; } - int DisSysCompCoilProp::calculate(EnergyPlusData & EP_UNUSED(state), - bool const LFLAG, // Initialization flag.If = 1, use laminar relationship - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - int const EP_UNUSED(i), // Linkage number - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + int DisSysCompCoilProp::calculate([[maybe_unused]] EnergyPlusData &state, + bool const LFLAG, // Initialization flag.If = 1, use laminar relationship + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + [[maybe_unused]] int const i, // Linkage number + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ) { @@ -2599,14 +2599,14 @@ namespace AirflowNetwork { return 1; } - int DisSysCompCoilProp::calculate(EnergyPlusData & EP_UNUSED(state), - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + int DisSysCompCoilProp::calculate([[maybe_unused]] EnergyPlusData &state, + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ) { @@ -2747,16 +2747,16 @@ namespace AirflowNetwork { return 1; } - int DisSysCompTermUnitProp::calculate(EnergyPlusData & EP_UNUSED(state), - bool const LFLAG, // Initialization flag.If = 1, use laminar relationship - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - int const i, // Linkage number - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + int DisSysCompTermUnitProp::calculate([[maybe_unused]] EnergyPlusData &state, + bool const LFLAG, // Initialization flag.If = 1, use laminar relationship + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + int const i, // Linkage number + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ) { @@ -2918,16 +2918,16 @@ namespace AirflowNetwork { return 1; } - int DisSysCompHXProp::calculate(EnergyPlusData & EP_UNUSED(state), - bool const LFLAG, // Initialization flag.If = 1, use laminar relationship - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - int const EP_UNUSED(i), // Linkage number - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + int DisSysCompHXProp::calculate([[maybe_unused]] EnergyPlusData &state, + bool const LFLAG, // Initialization flag.If = 1, use laminar relationship + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + [[maybe_unused]] int const i, // Linkage number + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ) { @@ -3068,14 +3068,14 @@ namespace AirflowNetwork { return 1; } - int DisSysCompHXProp::calculate(EnergyPlusData & EP_UNUSED(state), - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + int DisSysCompHXProp::calculate([[maybe_unused]] EnergyPlusData &state, + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ) { @@ -3206,15 +3206,15 @@ namespace AirflowNetwork { } int ZoneExhaustFan::calculate(EnergyPlusData &state, - bool const LFLAG, // Initialization flag.If = 1, use laminar relationship - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - int const i, // Linkage number - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + bool const LFLAG, // Initialization flag.If = 1, use laminar relationship + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + int const i, // Linkage number + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ) { // SUBROUTINE INFORMATION: @@ -3336,13 +3336,14 @@ namespace AirflowNetwork { return 1; } - int ZoneExhaustFan::calculate(EnergyPlusData &state, Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 control, // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + int ZoneExhaustFan::calculate(EnergyPlusData &state, + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + [[maybe_unused]] const Real64 multiplier, // Element multiplier + const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ) { // SUBROUTINE INFORMATION: @@ -3449,15 +3450,15 @@ namespace AirflowNetwork { } int HorizontalOpening::calculate(EnergyPlusData &state, - bool const LFLAG, // Initialization flag.If = 1, use laminar relationship - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - int const i, // Linkage number - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + bool const LFLAG, // Initialization flag.If = 1, use laminar relationship + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + int const i, // Linkage number + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ) { // SUBROUTINE INFORMATION: @@ -3581,15 +3582,15 @@ namespace AirflowNetwork { } int OutdoorAirFan::calculate(EnergyPlusData &state, - bool const LFLAG, // Initialization flag.If = 1, use laminar relationship - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - int const i, // Linkage number - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + bool const LFLAG, // Initialization flag.If = 1, use laminar relationship + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + int const i, // Linkage number + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ) { @@ -3701,15 +3702,15 @@ namespace AirflowNetwork { } int ReliefFlow::calculate(EnergyPlusData &state, - bool const LFLAG, // Initialization flag.If = 1, use laminar relationship - Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] - int const i, // Linkage number - const Real64 EP_UNUSED(multiplier), // Element multiplier - const Real64 EP_UNUSED(control), // Element control signal - const AirProperties &propN, // Node 1 properties - const AirProperties &propM, // Node 2 properties - std::array &F, // Airflow through the component [kg/s] - std::array &DF // Partial derivative: DF/DP + bool const LFLAG, // Initialization flag.If = 1, use laminar relationship + Real64 const PDROP, // Total pressure drop across a component (P1 - P2) [Pa] + int const i, // Linkage number + [[maybe_unused]] const Real64 multiplier, // Element multiplier + [[maybe_unused]] const Real64 control, // Element control signal + const AirProperties &propN, // Node 1 properties + const AirProperties &propM, // Node 2 properties + std::array &F, // Airflow through the component [kg/s] + std::array &DF // Partial derivative: DF/DP ) { diff --git a/src/EnergyPlus/BoilerSteam.cc b/src/EnergyPlus/BoilerSteam.cc index 16f426ab653..9d39b2bd763 100644 --- a/src/EnergyPlus/BoilerSteam.cc +++ b/src/EnergyPlus/BoilerSteam.cc @@ -111,7 +111,7 @@ namespace BoilerSteam { } void BoilerSpecs::simulate( - EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation), bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) + EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) { this->initialize(state); auto &sim_component(DataPlant::PlantLoop(this->LoopNum).LoopSide(this->LoopSideNum).Branch(this->BranchNum).Comp(this->CompNum)); @@ -119,7 +119,8 @@ namespace BoilerSteam { this->update(CurLoad, RunFlag, FirstHVACIteration); } - void BoilerSpecs::getDesignCapacities(EnergyPlusData &EP_UNUSED(state), const PlantLocation &, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) + void + BoilerSpecs::getDesignCapacities([[maybe_unused]] EnergyPlusData &state, const PlantLocation &, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) { MinLoad = this->NomCap * this->MinPartLoadRat; MaxLoad = this->NomCap * this->MaxPartLoadRat; @@ -786,9 +787,9 @@ namespace BoilerSteam { // Beginning of Record Keeping subroutines for the BOILER:SIMPLE Module - void BoilerSpecs::update(Real64 const MyLoad, // boiler operating load - bool const RunFlag, // boiler on when TRUE - bool const EP_UNUSED(FirstHVACIteration) // TRUE if First iteration of simulation + void BoilerSpecs::update(Real64 const MyLoad, // boiler operating load + bool const RunFlag, // boiler on when TRUE + [[maybe_unused]] bool const FirstHVACIteration // TRUE if First iteration of simulation ) { // SUBROUTINE INFORMATION: diff --git a/src/EnergyPlus/BoilerSteam.hh b/src/EnergyPlus/BoilerSteam.hh index 886428f83c2..1d5d301ab6b 100644 --- a/src/EnergyPlus/BoilerSteam.hh +++ b/src/EnergyPlus/BoilerSteam.hh @@ -140,13 +140,13 @@ namespace BoilerSteam { bool FirstHVACIteration // TRUE if First iteration of simulation ); - void simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; + void simulate([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; - void getDesignCapacities(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation), Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) override; + void getDesignCapacities(EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) override; void getSizingFactor(Real64 &sizFac) override; - void onInitLoopEquip(EnergyPlusData &EP_UNUSED(state), const PlantLocation &EP_UNUSED(calledFromLocation)) override; + void onInitLoopEquip([[maybe_unused]] EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation) override; static PlantComponent *factory(EnergyPlusData &state, std::string const &objectName); }; diff --git a/src/EnergyPlus/Boilers.cc b/src/EnergyPlus/Boilers.cc index 1ee45e66005..247fbdf8db2 100644 --- a/src/EnergyPlus/Boilers.cc +++ b/src/EnergyPlus/Boilers.cc @@ -116,8 +116,8 @@ namespace Boilers { } void BoilerSpecs::simulate(EnergyPlusData &state, - const PlantLocation &EP_UNUSED(calledFromLocation), - bool const EP_UNUSED(FirstHVACIteration), + [[maybe_unused]] const PlantLocation &calledFromLocation, + [[maybe_unused]] bool const FirstHVACIteration, Real64 &CurLoad, bool const RunFlag) { @@ -127,7 +127,11 @@ namespace Boilers { this->UpdateBoilerRecords(CurLoad, RunFlag); } - void BoilerSpecs::getDesignCapacities(EnergyPlusData &EP_UNUSED(state), const PlantLocation &EP_UNUSED(calledFromLocation), Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) + void BoilerSpecs::getDesignCapacities([[maybe_unused]] EnergyPlusData &state, + [[maybe_unused]] const PlantLocation &calledFromLocation, + Real64 &MaxLoad, + Real64 &MinLoad, + Real64 &OptLoad) { MinLoad = this->NomCap * this->MinPartLoadRat; MaxLoad = this->NomCap * this->MaxPartLoadRat; @@ -139,7 +143,7 @@ namespace Boilers { SizFactor = this->SizFac; } - void BoilerSpecs::onInitLoopEquip(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation)) + void BoilerSpecs::onInitLoopEquip(EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation) { this->InitBoiler(state); this->SizeBoiler(state); diff --git a/src/EnergyPlus/Boilers.hh b/src/EnergyPlus/Boilers.hh index fc07a6d9869..cab527f75fe 100644 --- a/src/EnergyPlus/Boilers.hh +++ b/src/EnergyPlus/Boilers.hh @@ -151,13 +151,13 @@ namespace Boilers { { } - void simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; + void simulate([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; - void getDesignCapacities(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation), Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) override; + void getDesignCapacities(EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) override; void getSizingFactor(Real64 &SizFac) override; - void onInitLoopEquip(EnergyPlusData &EP_UNUSED(state), const PlantLocation &EP_UNUSED(calledFromLocation)) override; + void onInitLoopEquip([[maybe_unused]] EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation) override; void SetupOutputVars(EnergyPlusData &state); diff --git a/src/EnergyPlus/BranchNodeConnections.cc b/src/EnergyPlus/BranchNodeConnections.cc index b662222de15..cf050636824 100644 --- a/src/EnergyPlus/BranchNodeConnections.cc +++ b/src/EnergyPlus/BranchNodeConnections.cc @@ -1270,7 +1270,7 @@ namespace BranchNodeConnections { } } - void TestInletOutletNodes(EnergyPlusData &state, bool &EP_UNUSED(ErrorsFound)) + void TestInletOutletNodes(EnergyPlusData &state, [[maybe_unused]] bool &ErrorsFound) { // SUBROUTINE INFORMATION: diff --git a/src/EnergyPlus/CTElectricGenerator.cc b/src/EnergyPlus/CTElectricGenerator.cc index 8964fdbac4e..b911f54ba1c 100644 --- a/src/EnergyPlus/CTElectricGenerator.cc +++ b/src/EnergyPlus/CTElectricGenerator.cc @@ -118,10 +118,11 @@ namespace CTElectricGenerator { return nullptr; // LCOV_EXCL_LINE } - void CTGeneratorData::simulate(EnergyPlusData &EP_UNUSED(state), const EnergyPlus::PlantLocation &EP_UNUSED(calledFromLocation), - bool EP_UNUSED(FirstHVACIteration), - Real64 &EP_UNUSED(CurLoad), - bool EP_UNUSED(RunFlag)) + void CTGeneratorData::simulate([[maybe_unused]] EnergyPlusData &state, + [[maybe_unused]] const EnergyPlus::PlantLocation &calledFromLocation, + [[maybe_unused]] bool FirstHVACIteration, + [[maybe_unused]] Real64 &CurLoad, + [[maybe_unused]] bool RunFlag) { // SUBROUTINE INFORMATION: // AUTHOR Dan Fisher diff --git a/src/EnergyPlus/ChillerAbsorption.cc b/src/EnergyPlus/ChillerAbsorption.cc index 8582ee06e48..db161381b91 100644 --- a/src/EnergyPlus/ChillerAbsorption.cc +++ b/src/EnergyPlus/ChillerAbsorption.cc @@ -209,7 +209,7 @@ namespace ChillerAbsorption { sizFac = this->SizFac; } - void BLASTAbsorberSpecs::getDesignTemperatures(Real64 &tempDesCondIn, Real64 &EP_UNUSED(TempDesEvapOut)) + void BLASTAbsorberSpecs::getDesignTemperatures(Real64 &tempDesCondIn, [[maybe_unused]] Real64 &TempDesEvapOut) { tempDesCondIn = this->TempDesCondIn; } diff --git a/src/EnergyPlus/ChillerAbsorption.hh b/src/EnergyPlus/ChillerAbsorption.hh index 70d4b27a6e5..7cf0c591476 100644 --- a/src/EnergyPlus/ChillerAbsorption.hh +++ b/src/EnergyPlus/ChillerAbsorption.hh @@ -195,9 +195,9 @@ namespace ChillerAbsorption { static PlantComponent *factory(EnergyPlusData &state, std::string const &objectName); - void simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; + void simulate([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; - void onInitLoopEquip(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation) override; + void onInitLoopEquip([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation) override; void getDesignCapacities(EnergyPlusData &state, const PlantLocation &calledFromLocation, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) override; diff --git a/src/EnergyPlus/ChillerElectricEIR.cc b/src/EnergyPlus/ChillerElectricEIR.cc index e845d04e8df..2d1fdc74d41 100644 --- a/src/EnergyPlus/ChillerElectricEIR.cc +++ b/src/EnergyPlus/ChillerElectricEIR.cc @@ -179,7 +179,8 @@ namespace ChillerElectricEIR { } } - void ElectricEIRChillerSpecs::getDesignCapacities(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) + void ElectricEIRChillerSpecs::getDesignCapacities( + [[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) { if (calledFromLocation.loopNum == this->CWLoopNum) { MinLoad = this->RefCap * this->MinPartLoadRat; diff --git a/src/EnergyPlus/ChillerElectricEIR.hh b/src/EnergyPlus/ChillerElectricEIR.hh index 813f49f6563..613e0d0682d 100644 --- a/src/EnergyPlus/ChillerElectricEIR.hh +++ b/src/EnergyPlus/ChillerElectricEIR.hh @@ -229,7 +229,7 @@ namespace ChillerElectricEIR { void setupOutputVars(EnergyPlusData &state); - void simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; + void simulate([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; void getDesignCapacities(EnergyPlusData &state, const PlantLocation &calledFromLocation, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) override; diff --git a/src/EnergyPlus/ChillerIndirectAbsorption.cc b/src/EnergyPlus/ChillerIndirectAbsorption.cc index 61b9e95bce2..225a2783781 100644 --- a/src/EnergyPlus/ChillerIndirectAbsorption.cc +++ b/src/EnergyPlus/ChillerIndirectAbsorption.cc @@ -172,7 +172,8 @@ namespace ChillerIndirectAbsorption { } } - void IndirectAbsorberSpecs::getDesignCapacities(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) + void IndirectAbsorberSpecs::getDesignCapacities( + [[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) { if (calledFromLocation.loopNum == this->CWLoopNum) { MinLoad = this->NomCap * this->MinPartLoadRat; diff --git a/src/EnergyPlus/ChillerIndirectAbsorption.hh b/src/EnergyPlus/ChillerIndirectAbsorption.hh index 584c4893091..4d9d33f864f 100644 --- a/src/EnergyPlus/ChillerIndirectAbsorption.hh +++ b/src/EnergyPlus/ChillerIndirectAbsorption.hh @@ -216,13 +216,13 @@ namespace ChillerIndirectAbsorption { static PlantComponent *factory(EnergyPlusData &state, std::string const &objectName); - void simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; + void simulate([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; void getDesignCapacities(EnergyPlusData &state, const PlantLocation &calledFromLocation, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) override; void getSizingFactor(Real64 &sizFac) override; - void onInitLoopEquip(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation) override; + void onInitLoopEquip([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation) override; void initialize(EnergyPlusData &state, bool RunFlag, Real64 MyLoad); diff --git a/src/EnergyPlus/ChillerReformulatedEIR.cc b/src/EnergyPlus/ChillerReformulatedEIR.cc index eb28a4d4985..8e2a5fc7000 100644 --- a/src/EnergyPlus/ChillerReformulatedEIR.cc +++ b/src/EnergyPlus/ChillerReformulatedEIR.cc @@ -135,7 +135,8 @@ namespace ChillerReformulatedEIR { return nullptr; // LCOV_EXCL_LINE } - void ReformulatedEIRChillerSpecs::getDesignCapacities(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) + void ReformulatedEIRChillerSpecs::getDesignCapacities( + [[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) { if (calledFromLocation.loopNum == this->CWLoopNum) { MinLoad = this->RefCap * this->MinPartLoadRat; diff --git a/src/EnergyPlus/ChillerReformulatedEIR.hh b/src/EnergyPlus/ChillerReformulatedEIR.hh index de15656fbfe..c97c590ff9b 100644 --- a/src/EnergyPlus/ChillerReformulatedEIR.hh +++ b/src/EnergyPlus/ChillerReformulatedEIR.hh @@ -251,7 +251,7 @@ namespace ChillerReformulatedEIR { static PlantComponent *factory(EnergyPlusData &state, std::string const &objectName); - void simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; + void simulate([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; void getDesignCapacities(EnergyPlusData &state, const PlantLocation &calledFromLocation, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) override; @@ -259,7 +259,7 @@ namespace ChillerReformulatedEIR { void getSizingFactor(Real64 &sizFac) override; - void onInitLoopEquip(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation) override; + void onInitLoopEquip([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation) override; void initialize(EnergyPlusData &state, bool RunFlag, Real64 MyLoad); diff --git a/src/EnergyPlus/Coils/CoilCoolingDXCurveFitOperatingMode.cc b/src/EnergyPlus/Coils/CoilCoolingDXCurveFitOperatingMode.cc index 22b97c5ace6..a4b9c3ac4d6 100644 --- a/src/EnergyPlus/Coils/CoilCoolingDXCurveFitOperatingMode.cc +++ b/src/EnergyPlus/Coils/CoilCoolingDXCurveFitOperatingMode.cc @@ -224,7 +224,7 @@ void CoilCoolingDXCurveFitOperatingMode::CalcOperatingMode(EnergyPlus::EnergyPlu Real64 &speedRatio, int &fanOpMode, DataLoopNode::NodeData &condInletNode, - DataLoopNode::NodeData &EP_UNUSED(condOutletNode)) + [[maybe_unused]] DataLoopNode::NodeData &condOutletNode) { // Currently speedNum is 1-based, while this->speeds are zero-based diff --git a/src/EnergyPlus/CondenserLoopTowers.cc b/src/EnergyPlus/CondenserLoopTowers.cc index 410d43350c5..d52fd0be5ff 100644 --- a/src/EnergyPlus/CondenserLoopTowers.cc +++ b/src/EnergyPlus/CondenserLoopTowers.cc @@ -130,8 +130,9 @@ namespace CondenserLoopTowers { return nullptr; // LCOV_EXCL_LINE } - void CoolingTower::simulate(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation), - bool const EP_UNUSED(FirstHVACIteration), + void CoolingTower::simulate(EnergyPlusData &state, + [[maybe_unused]] const PlantLocation &calledFromLocation, + [[maybe_unused]] bool const FirstHVACIteration, Real64 &CurLoad, bool const RunFlag) { @@ -150,7 +151,11 @@ namespace CondenserLoopTowers { this->report(RunFlag); } - void CoolingTower::getDesignCapacities(EnergyPlusData &EP_UNUSED(state), const PlantLocation &EP_UNUSED(calledFromLocation), Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) + void CoolingTower::getDesignCapacities([[maybe_unused]] EnergyPlusData &state, + [[maybe_unused]] const PlantLocation &calledFromLocation, + Real64 &MaxLoad, + Real64 &MinLoad, + Real64 &OptLoad) { MinLoad = 0.0; MaxLoad = this->TowerNominalCapacity * this->HeatRejectCapNomCapSizingRatio; @@ -162,7 +167,7 @@ namespace CondenserLoopTowers { SizFactor = this->SizFac; } - void CoolingTower::onInitLoopEquip(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation)) + void CoolingTower::onInitLoopEquip(EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation) { this->initialize(state); if (this->TowerType_Num == DataPlant::TypeOf_CoolingTower_VarSpdMerkel) { diff --git a/src/EnergyPlus/CondenserLoopTowers.hh b/src/EnergyPlus/CondenserLoopTowers.hh index 14710aa9751..a4bbc993252 100644 --- a/src/EnergyPlus/CondenserLoopTowers.hh +++ b/src/EnergyPlus/CondenserLoopTowers.hh @@ -390,13 +390,13 @@ namespace CondenserLoopTowers { { } - void simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; + void simulate([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; - void getDesignCapacities(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation), Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) override; + void getDesignCapacities(EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) override; void getSizingFactor(Real64 &SizFac) override; - void onInitLoopEquip(EnergyPlusData &EP_UNUSED(state), const PlantLocation &EP_UNUSED(calledFromLocation)) override; + void onInitLoopEquip([[maybe_unused]] EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation) override; void initialize(EnergyPlusData &state); diff --git a/src/EnergyPlus/ConvectionCoefficients.cc b/src/EnergyPlus/ConvectionCoefficients.cc index 5c94ea3b520..f4f564b36cf 100644 --- a/src/EnergyPlus/ConvectionCoefficients.cc +++ b/src/EnergyPlus/ConvectionCoefficients.cc @@ -8139,7 +8139,7 @@ namespace ConvectionCoefficients { Real64 const SurfTemp, Real64 const AirTemp, Real64 const WindAtZ, - Real64 const EP_UNUSED(WindDirect), // Wind direction measured clockwise from geographhic North + [[maybe_unused]] Real64 const WindDirect, // Wind direction measured clockwise from geographhic North Real64 const RoofArea, Real64 const RoofPerimeter) { diff --git a/src/EnergyPlus/DXCoils.cc b/src/EnergyPlus/DXCoils.cc index c97fea2e6f5..d628c6755c6 100644 --- a/src/EnergyPlus/DXCoils.cc +++ b/src/EnergyPlus/DXCoils.cc @@ -490,11 +490,11 @@ namespace DXCoils { } void SimDXCoilMultiMode(EnergyPlusData &state, - std::string const &CompName, // name of the fan coil unit - int const EP_UNUSED(CompOp), // compressor operation; 1=on, 0=off !unused1208 - bool const FirstHVACIteration, // true if first hvac iteration - Real64 const PartLoadRatio, // part load ratio - int const DehumidMode, // dehumidification mode (0=normal, 1=enhanced) + std::string const &CompName, // name of the fan coil unit + [[maybe_unused]] int const CompOp, // compressor operation; 1=on, 0=off !unused1208 + bool const FirstHVACIteration, // true if first hvac iteration + Real64 const PartLoadRatio, // part load ratio + int const DehumidMode, // dehumidification mode (0=normal, 1=enhanced) int &CompIndex, int const FanOpMode // allows parent object to control fan mode ) @@ -15546,7 +15546,7 @@ namespace DXCoils { } Real64 CalcSecondaryDXCoilsSHR(EnergyPlusData &state, - int const EP_UNUSED(DXCoilNum), + [[maybe_unused]] int const DXCoilNum, Real64 const EvapAirMassFlow, Real64 const TotalHeatRemovalRate, Real64 const PartLoadRatio, diff --git a/src/EnergyPlus/DXFEarClipping.cc b/src/EnergyPlus/DXFEarClipping.cc index 57d78ce6e8c..9eb1a24e200 100644 --- a/src/EnergyPlus/DXFEarClipping.cc +++ b/src/EnergyPlus/DXFEarClipping.cc @@ -667,7 +667,7 @@ namespace DXFEarClipping { void CalcWallCoordinateTransformation(int const nsides, Array1D &polygon, Real64 const surfazimuth, - Real64 const EP_UNUSED(surftilt), // unused1208 + [[maybe_unused]] Real64 const surftilt, // unused1208 Array1D &xvt, Array1D &yvt, Array1D &zvt) @@ -730,7 +730,7 @@ namespace DXFEarClipping { void CalcRfFlrCoordinateTransformation(int const nsides, Array1D &polygon, - Real64 const EP_UNUSED(surfazimuth), // unused1208 + [[maybe_unused]] Real64 const surfazimuth, // unused1208 Real64 const surftilt, Array1D &xvt, Array1D &yvt, @@ -788,7 +788,7 @@ namespace DXFEarClipping { } } - void reorder(int &EP_UNUSED(nvert)) // unused1208 + void reorder([[maybe_unused]] int &nvert) // unused1208 { // Locals diff --git a/src/EnergyPlus/DataEnvironment.cc b/src/EnergyPlus/DataEnvironment.cc index f70378bb5f5..7421de17b48 100644 --- a/src/EnergyPlus/DataEnvironment.cc +++ b/src/EnergyPlus/DataEnvironment.cc @@ -600,7 +600,8 @@ namespace DataEnvironment { ShowFatalError(state, "Program terminates due to preceding condition(s)."); } - void SetWindSpeedAt(int const NumItems, const Array1D &Heights, Array1D &LocalWindSpeed, std::string const &EP_UNUSED(Settings)) + void + SetWindSpeedAt(int const NumItems, const Array1D &Heights, Array1D &LocalWindSpeed, [[maybe_unused]] std::string const &Settings) { // SUBROUTINE INFORMATION: diff --git a/src/EnergyPlus/DataTimings.cc b/src/EnergyPlus/DataTimings.cc index 7174dc8a833..1df7a9ce877 100644 --- a/src/EnergyPlus/DataTimings.cc +++ b/src/EnergyPlus/DataTimings.cc @@ -96,7 +96,7 @@ namespace DataTimings { void epStartTime( #ifdef EP_NO_Timings - std::string const &EP_UNUSED(ctimingElementstring) + [[maybe_unused]] std::string const &ctimingElementstring #endif #ifdef EP_Timings std::string const &ctimingElementstring @@ -158,12 +158,12 @@ namespace DataTimings { void epStopTime( #ifdef EP_NO_Timings - std::string const &EP_UNUSED(ctimingElementstring), - Optional_bool_const EP_UNUSED(printit), // true if it should be printed here. - Optional_string_const EP_UNUSED(wprint) // only needed (and assumed, if printit is true) + [[maybe_unused]] std::string const &ctimingElementstring, + [[maybe_unused]] Optional_bool_const printit, // true if it should be printed here. + [[maybe_unused]] Optional_string_const wprint // only needed (and assumed, if printit is true) #endif #ifdef EP_Timings - std::string const &ctimingElementstring, + std::string const &ctimingElementstring, Optional_bool_const printit, // true if it should be printed here. Optional_string_const wprint // only needed (and assumed, if printit is true) #endif @@ -244,10 +244,10 @@ namespace DataTimings { void epSummaryTimes( #ifdef EP_NO_Timings InputOutputFile &, - Real64 &EP_UNUSED(TimeUsed_CPUTime) + [[maybe_unused]] Real64 &TimeUsed_CPUTime #endif #ifdef EP_Timings - InputOutputFile &auditFile, + InputOutputFile &auditFile, Real64 &TimeUsed_CPUTime #endif ) diff --git a/src/EnergyPlus/DaylightingManager.cc b/src/EnergyPlus/DaylightingManager.cc index 951945b991c..952ef7240fd 100644 --- a/src/EnergyPlus/DaylightingManager.cc +++ b/src/EnergyPlus/DaylightingManager.cc @@ -2702,7 +2702,7 @@ namespace DaylightingManager { void InitializeCFSStateData(BSDFRefPoints &StateRefPoint, BSDFRefPointsGeomDescr &DaylghtGeomDescr, - int const EP_UNUSED(ZoneNum), // Current zone number + [[maybe_unused]] int const ZoneNum, // Current zone number int const iWin, Vector3 const &RefPoint, // reference point int const CurFenState, @@ -2718,8 +2718,8 @@ namespace DaylightingManager { Real64 const DWY, Vector3 const &WNorm, // unit vector from window (point towards outside) Real64 const WinElArea, - int const EP_UNUSED(CalledFrom), - Optional_int_const EP_UNUSED(MapNum)) + [[maybe_unused]] int const CalledFrom, + [[maybe_unused]] Optional_int_const MapNum) { // SUBROUTINE INFORMATION: // AUTHOR Simon Vidanovic @@ -8788,11 +8788,11 @@ namespace DaylightingManager { } void DayltgDirectIllumComplexFenestration(EnergyPlusData &state, - int const IWin, // Window index - int const WinEl, // Current window element counter - int const IHR, // Hour of day - int const EP_UNUSED(ZoneNum), // Zone number - int const iRefPoint, // reference point index + int const IWin, // Window index + int const WinEl, // Current window element counter + int const IHR, // Hour of day + [[maybe_unused]] int const ZoneNum, // Zone number + int const iRefPoint, // reference point index int const CalledFrom, Optional_int_const MapNum) { @@ -8908,9 +8908,9 @@ namespace DaylightingManager { } void DayltgDirectSunDiskComplexFenestration(EnergyPlusData &state, - int const iWin, // Window index - int const EP_UNUSED(ZoneNum), // Zone number - int const iHour, // Hour of day + int const iWin, // Window index + [[maybe_unused]] int const ZoneNum, // Zone number + int const iHour, // Hour of day int const iRefPoint, int const NumEl, // Total number of window elements Real64 const AZVIEW, // Azimuth of view vector in absolute coord system for diff --git a/src/EnergyPlus/DesiccantDehumidifiers.cc b/src/EnergyPlus/DesiccantDehumidifiers.cc index a7872900774..716acc1c94a 100644 --- a/src/EnergyPlus/DesiccantDehumidifiers.cc +++ b/src/EnergyPlus/DesiccantDehumidifiers.cc @@ -1990,7 +1990,7 @@ namespace DesiccantDehumidifiers { void ControlDesiccantDehumidifier(EnergyPlusData &state, int const DesicDehumNum, // number of the current dehumidifier being simulated Real64 &HumRatNeeded, // process air leaving humidity ratio set by controller [kg water/kg air] - bool const EP_UNUSED(FirstHVACIteration) // TRUE if 1st HVAC simulation of system timestep !unused1208 + [[maybe_unused]] bool const FirstHVACIteration // TRUE if 1st HVAC simulation of system timestep !unused1208 ) { diff --git a/src/EnergyPlus/DualDuct.cc b/src/EnergyPlus/DualDuct.cc index 28baea0ae43..b9db22e899b 100644 --- a/src/EnergyPlus/DualDuct.cc +++ b/src/EnergyPlus/DualDuct.cc @@ -2272,7 +2272,10 @@ namespace DualDuct { } } - void GetDualDuctOutdoorAirRecircUse(EnergyPlusData &state, std::string const &EP_UNUSED(CompTypeName), std::string const &CompName, bool &RecircIsUsed) + void GetDualDuctOutdoorAirRecircUse(EnergyPlusData &state, + [[maybe_unused]] std::string const &CompTypeName, + std::string const &CompName, + bool &RecircIsUsed) { // SUBROUTINE INFORMATION: diff --git a/src/EnergyPlus/EcoRoofManager.cc b/src/EnergyPlus/EcoRoofManager.cc index ab8e721f3bf..2fe2cc5f6e4 100644 --- a/src/EnergyPlus/EcoRoofManager.cc +++ b/src/EnergyPlus/EcoRoofManager.cc @@ -676,10 +676,10 @@ namespace EcoRoofManager { Real64 const Vfluxg, // Water mass flux from soil surface [m/s] int &ConstrNum, // Indicator for construction index for the current surface Real64 &Alphag, - int const EP_UNUSED(unit), // unused1208 - Real64 const EP_UNUSED(Tg), // unused1208 - Real64 const EP_UNUSED(Tf), // unused1208 - Real64 const EP_UNUSED(Qsoil) // unused1208 + [[maybe_unused]] int const unit, // unused1208 + [[maybe_unused]] Real64 const Tg, // unused1208 + [[maybe_unused]] Real64 const Tf, // unused1208 + [[maybe_unused]] Real64 const Qsoil // unused1208 ) { // SUBROUTINE INFORMATION diff --git a/src/EnergyPlus/ElectricBaseboardRadiator.cc b/src/EnergyPlus/ElectricBaseboardRadiator.cc index 20e417a8b91..d8a0c60ac0f 100644 --- a/src/EnergyPlus/ElectricBaseboardRadiator.cc +++ b/src/EnergyPlus/ElectricBaseboardRadiator.cc @@ -144,7 +144,7 @@ namespace ElectricBaseboardRadiator { void SimElecBaseboard(EnergyPlusData &state, std::string const &EquipName, - int const EP_UNUSED(ActualZoneNum), + [[maybe_unused]] int const ActualZoneNum, int const ControlledZoneNum, bool const FirstHVACIteration, Real64 &PowerMet, @@ -767,7 +767,7 @@ namespace ElectricBaseboardRadiator { } } - void CalcElectricBaseboard(EnergyPlusData &state, int const BaseboardNum, int const EP_UNUSED(ControlledZoneNum)) + void CalcElectricBaseboard(EnergyPlusData &state, int const BaseboardNum, [[maybe_unused]] int const ControlledZoneNum) { // SUBROUTINE INFORMATION: // AUTHOR Richard Liesen diff --git a/src/EnergyPlus/EnergyPlus.hh b/src/EnergyPlus/EnergyPlus.hh index 701c709200e..6f3b4d8d765 100644 --- a/src/EnergyPlus/EnergyPlus.hh +++ b/src/EnergyPlus/EnergyPlus.hh @@ -58,9 +58,6 @@ #include -// macro to suppress unused parameter -// UNUSED( foo ); -#define EP_UNUSED(expr) // macro to guarantee array sizing in debug builds #define EP_SIZE_CHECK(array, min_size) assert(min_size >= 0);assert(array.size() >= (size_t)min_size) diff --git a/src/EnergyPlus/EvaporativeFluidCoolers.cc b/src/EnergyPlus/EvaporativeFluidCoolers.cc index 5c07803d286..532f2385cc9 100644 --- a/src/EnergyPlus/EvaporativeFluidCoolers.cc +++ b/src/EnergyPlus/EvaporativeFluidCoolers.cc @@ -966,7 +966,7 @@ namespace EvaporativeFluidCoolers { _SizFac = this->SizFac; } - void EvapFluidCoolerSpecs::onInitLoopEquip(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation)) + void EvapFluidCoolerSpecs::onInitLoopEquip(EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation) { this->InitEvapFluidCooler(state); this->SizeEvapFluidCooler(state); @@ -992,9 +992,9 @@ namespace EvaporativeFluidCoolers { } void EvapFluidCoolerSpecs::simulate(EnergyPlusData &state, - const PlantLocation &EP_UNUSED(calledFromLocation), - bool EP_UNUSED(FirstHVACIteration), - Real64 &EP_UNUSED(CurLoad), + [[maybe_unused]] const PlantLocation &calledFromLocation, + [[maybe_unused]] bool FirstHVACIteration, + [[maybe_unused]] Real64 &CurLoad, bool RunFlag) { diff --git a/src/EnergyPlus/EvaporativeFluidCoolers.hh b/src/EnergyPlus/EvaporativeFluidCoolers.hh index 31ab8351878..2c425095980 100644 --- a/src/EnergyPlus/EvaporativeFluidCoolers.hh +++ b/src/EnergyPlus/EvaporativeFluidCoolers.hh @@ -257,7 +257,7 @@ namespace EvaporativeFluidCoolers { void getDesignCapacities(EnergyPlusData &state, const PlantLocation &, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) override; - void simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; + void simulate([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; void InitEvapFluidCooler(EnergyPlusData &state); diff --git a/src/EnergyPlus/Fans.cc b/src/EnergyPlus/Fans.cc index fa5f390e8e8..6609b4708cc 100644 --- a/src/EnergyPlus/Fans.cc +++ b/src/EnergyPlus/Fans.cc @@ -1003,7 +1003,7 @@ namespace Fans { void InitFan(EnergyPlusData &state, int const FanNum, - bool const EP_UNUSED(FirstHVACIteration) // unused1208 + [[maybe_unused]] bool const FirstHVACIteration // unused1208 ) { @@ -3108,8 +3108,8 @@ namespace Fans { } } - Real64 FanDesDT(int const FanNum, // index of fan in Fan array - Real64 const EP_UNUSED(FanVolFlow) // fan volumetric flow rate [m3/s] + Real64 FanDesDT(int const FanNum, // index of fan in Fan array + [[maybe_unused]] Real64 const FanVolFlow // fan volumetric flow rate [m3/s] ) { // FUNCTION INFORMATION: diff --git a/src/EnergyPlus/FluidCoolers.cc b/src/EnergyPlus/FluidCoolers.cc index 2b353900f86..a174a864cbf 100644 --- a/src/EnergyPlus/FluidCoolers.cc +++ b/src/EnergyPlus/FluidCoolers.cc @@ -127,9 +127,9 @@ namespace FluidCoolers { } void FluidCoolerspecs::simulate(EnergyPlusData &state, - const PlantLocation &EP_UNUSED(calledFromLocation), - bool const EP_UNUSED(FirstHVACIteration), - Real64 &EP_UNUSED(CurLoad), + [[maybe_unused]] const PlantLocation &calledFromLocation, + [[maybe_unused]] bool const FirstHVACIteration, + [[maybe_unused]] Real64 &CurLoad, bool const RunFlag) { this->initialize(state); @@ -142,13 +142,17 @@ namespace FluidCoolers { this->report(RunFlag); } - void FluidCoolerspecs::onInitLoopEquip(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation)) + void FluidCoolerspecs::onInitLoopEquip(EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation) { this->initialize(state); this->size(state); } - void FluidCoolerspecs::getDesignCapacities(EnergyPlusData &EP_UNUSED(state), const PlantLocation &EP_UNUSED(calledFromLocation), Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) + void FluidCoolerspecs::getDesignCapacities([[maybe_unused]] EnergyPlusData &state, + [[maybe_unused]] const PlantLocation &calledFromLocation, + Real64 &MaxLoad, + Real64 &MinLoad, + Real64 &OptLoad) { MaxLoad = this->FluidCoolerNominalCapacity; OptLoad = this->FluidCoolerNominalCapacity; diff --git a/src/EnergyPlus/FluidCoolers.hh b/src/EnergyPlus/FluidCoolers.hh index 1cb9e3136c7..c61cff01d1c 100644 --- a/src/EnergyPlus/FluidCoolers.hh +++ b/src/EnergyPlus/FluidCoolers.hh @@ -193,15 +193,15 @@ namespace FluidCoolers { void calcTwoSpeed(EnergyPlusData &state); - void simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; + void simulate([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; void getDesignCapacities(EnergyPlusData &state, - const PlantLocation &EP_UNUSED(calledFromLocation), - Real64 &EP_UNUSED(MaxLoad), - Real64 &EP_UNUSED(MinLoad), - Real64 &EP_UNUSED(OptLoad)) override; + [[maybe_unused]] const PlantLocation &calledFromLocation, + [[maybe_unused]] Real64 &MaxLoad, + [[maybe_unused]] Real64 &MinLoad, + [[maybe_unused]] Real64 &OptLoad) override; - void onInitLoopEquip(EnergyPlusData &EP_UNUSED(state), const PlantLocation &EP_UNUSED(calledFromLocation)) override; + void onInitLoopEquip([[maybe_unused]] EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation) override; static PlantComponent *factory(EnergyPlusData &state, int typeOf, std::string objectName); }; diff --git a/src/EnergyPlus/FuelCellElectricGenerator.cc b/src/EnergyPlus/FuelCellElectricGenerator.cc index e72c62fb22b..74e2c129775 100644 --- a/src/EnergyPlus/FuelCellElectricGenerator.cc +++ b/src/EnergyPlus/FuelCellElectricGenerator.cc @@ -1349,7 +1349,10 @@ namespace FuelCellElectricGenerator { } } - void FCDataStruct::CalcFuelCellGeneratorModel(EnergyPlusData &state, bool const RunFlag, Real64 const MyLoad, bool const EP_UNUSED(FirstHVACIteration)) + void FCDataStruct::CalcFuelCellGeneratorModel(EnergyPlusData &state, + bool const RunFlag, + Real64 const MyLoad, + [[maybe_unused]] bool const FirstHVACIteration) { // SUBROUTINE INFORMATION: // AUTHOR Brent Griffith @@ -1894,7 +1897,7 @@ namespace FuelCellElectricGenerator { void FCDataStruct::ManageElectStorInteractions(EnergyPlusData &state, Real64 const Pdemand, - Real64 const EP_UNUSED(PpcuLosses), + [[maybe_unused]] Real64 const PpcuLosses, bool &Constrained, Real64 &Pstorage, Real64 &PgridOverage // electricity that can't be stored and needs to go out @@ -3110,17 +3113,22 @@ namespace FuelCellElectricGenerator { this->ExhaustHX.WaterOutletEnthalpy = DataLoopNode::Node(this->ExhaustHX.WaterInNode).Enthalpy + this->ExhaustHX.qHX; } - void FCDataStruct::getDesignCapacities(EnergyPlusData &EP_UNUSED(state), const PlantLocation &EP_UNUSED(calledFromLocation), Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) + void FCDataStruct::getDesignCapacities([[maybe_unused]] EnergyPlusData &state, + [[maybe_unused]] const PlantLocation &calledFromLocation, + Real64 &MaxLoad, + Real64 &MinLoad, + Real64 &OptLoad) { MaxLoad = 0.0; MinLoad = 0.0; OptLoad = 0.0; } - void FCDataStruct::simulate(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation), + void FCDataStruct::simulate(EnergyPlusData &state, + [[maybe_unused]] const PlantLocation &calledFromLocation, bool FirstHVACIteration, - Real64 &EP_UNUSED(CurLoad), - bool EP_UNUSED(RunFlag)) + [[maybe_unused]] Real64 &CurLoad, + [[maybe_unused]] bool RunFlag) { if (this->TypeOf == DataPlant::TypeOf_Generator_FCStackCooler) { PlantUtilities::UpdateComponentHeatRecoverySide(state, this->CWLoopNum, @@ -3399,7 +3407,7 @@ namespace FuelCellElectricGenerator { } // over number of Fuel cells } - void FCDataStruct::CalcUpdateHeatRecovery(bool const EP_UNUSED(FirstHVACIteration)) + void FCDataStruct::CalcUpdateHeatRecovery([[maybe_unused]] bool const FirstHVACIteration) { // SUBROUTINE INFORMATION: diff --git a/src/EnergyPlus/FuelCellElectricGenerator.hh b/src/EnergyPlus/FuelCellElectricGenerator.hh index 59f74d69a73..161552a6cd3 100644 --- a/src/EnergyPlus/FuelCellElectricGenerator.hh +++ b/src/EnergyPlus/FuelCellElectricGenerator.hh @@ -548,7 +548,7 @@ namespace FuelCellElectricGenerator { void setupOutputVars(EnergyPlusData &state); - void simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; + void simulate([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; void FigureAirHeatCap(Real64 FluidTemp, Real64 &Cp); diff --git a/src/EnergyPlus/Furnaces.cc b/src/EnergyPlus/Furnaces.cc index 3d71784bd39..11363132247 100644 --- a/src/EnergyPlus/Furnaces.cc +++ b/src/EnergyPlus/Furnaces.cc @@ -5873,13 +5873,13 @@ namespace Furnaces { } void SetOnOffMassFlowRate(EnergyPlusData &state, - int const FurnaceNum, // index to furnace - int const EP_UNUSED(AirLoopNum), // index to air loop !unused1208 - Real64 &OnOffAirFlowRatio, // ratio of coil on to coil off air flow rate - int const OpMode, // fan operating mode - Real64 const EP_UNUSED(ZoneLoad), // sensible load to be met (W) !unused1208 - Real64 const MoistureLoad, // moisture load to be met (W) - Real64 const PartLoadRatio // coil part-load ratio + int const FurnaceNum, // index to furnace + [[maybe_unused]] int const AirLoopNum, // index to air loop !unused1208 + Real64 &OnOffAirFlowRatio, // ratio of coil on to coil off air flow rate + int const OpMode, // fan operating mode + [[maybe_unused]] Real64 const ZoneLoad, // sensible load to be met (W) !unused1208 + Real64 const MoistureLoad, // moisture load to be met (W) + Real64 const PartLoadRatio // coil part-load ratio ) { @@ -11743,15 +11743,15 @@ namespace Furnaces { } void SetOnOffMassFlowRateVSCoil(EnergyPlusData &state, - int const FurnaceNum, // index to furnace - int const ZoneNum, // index to zone - bool const FirstHVACIteration, // Flag for 1st HVAC iteration - int const EP_UNUSED(AirLoopNum), // index to air loop !unused1208 - Real64 &OnOffAirFlowRatio, // ratio of coil on to coil off air flow rate - int const EP_UNUSED(OpMode), // fan operating mode - Real64 const EP_UNUSED(QZnReq), // sensible load to be met (W) !unused1208 - Real64 const EP_UNUSED(MoistureLoad), // moisture load to be met (W) - Real64 &PartLoadRatio // coil part-load ratio + int const FurnaceNum, // index to furnace + int const ZoneNum, // index to zone + bool const FirstHVACIteration, // Flag for 1st HVAC iteration + [[maybe_unused]] int const AirLoopNum, // index to air loop !unused1208 + Real64 &OnOffAirFlowRatio, // ratio of coil on to coil off air flow rate + [[maybe_unused]] int const OpMode, // fan operating mode + [[maybe_unused]] Real64 const QZnReq, // sensible load to be met (W) !unused1208 + [[maybe_unused]] Real64 const MoistureLoad, // moisture load to be met (W) + Real64 &PartLoadRatio // coil part-load ratio ) { diff --git a/src/EnergyPlus/General.cc b/src/EnergyPlus/General.cc index 556d4a5acc2..8f0e8d5209f 100644 --- a/src/EnergyPlus/General.cc +++ b/src/EnergyPlus/General.cc @@ -1593,7 +1593,7 @@ namespace General { } std::string TrimSigDigits(int const IntegerValue, - Optional_int_const EP_UNUSED(SigDigits) // ignored + [[maybe_unused]] Optional_int_const SigDigits // ignored ) { return format("{}", IntegerValue); @@ -1605,7 +1605,7 @@ namespace General { } std::string RoundSigDigits(int const IntegerValue, - Optional_int_const EP_UNUSED(SigDigits) // ignored + [[maybe_unused]] Optional_int_const SigDigits // ignored ) { return format("{}", IntegerValue); diff --git a/src/EnergyPlus/GeneratorDynamicsManager.cc b/src/EnergyPlus/GeneratorDynamicsManager.cc index 9e92cc8f888..1c2ecdc0316 100644 --- a/src/EnergyPlus/GeneratorDynamicsManager.cc +++ b/src/EnergyPlus/GeneratorDynamicsManager.cc @@ -146,18 +146,18 @@ namespace GeneratorDynamicsManager { } void ManageGeneratorControlState(EnergyPlusData &state, - GeneratorType const GeneratorType, // type of Generator - std::string const &EP_UNUSED(GeneratorName), // user specified name of Generator - int const GeneratorNum, // Generator number - bool const RunFlagElectCenter, // TRUE when Generator operating per electric load center request - bool const RunFlagPlant, // TRUE when generator operating per Plant request (always false) - Real64 const ElecLoadRequest, // Generator Electrical power demand - Real64 const ThermalLoadRequest, // cogenerator Thermal power demand - Real64 &ElecLoadProvided, // power allowed - int &OperatingMode, // operating mode - Real64 &PLRforSubtimestepStartUp, // part load ratio for switch to normal from start up - Real64 &PLRforSubtimestepShutDown, // part load ratio for switch from cool down to other - bool const EP_UNUSED(FirstHVACIteration) // True is this is first HVAC iteration + GeneratorType const GeneratorType, // type of Generator + [[maybe_unused]] std::string const &GeneratorName, // user specified name of Generator + int const GeneratorNum, // Generator number + bool const RunFlagElectCenter, // TRUE when Generator operating per electric load center request + bool const RunFlagPlant, // TRUE when generator operating per Plant request (always false) + Real64 const ElecLoadRequest, // Generator Electrical power demand + Real64 const ThermalLoadRequest, // cogenerator Thermal power demand + Real64 &ElecLoadProvided, // power allowed + int &OperatingMode, // operating mode + Real64 &PLRforSubtimestepStartUp, // part load ratio for switch to normal from start up + Real64 &PLRforSubtimestepShutDown, // part load ratio for switch from cool down to other + [[maybe_unused]] bool const FirstHVACIteration // True is this is first HVAC iteration ) { @@ -741,14 +741,14 @@ namespace GeneratorDynamicsManager { OperatingMode = newOpMode; } - void ManageGeneratorFuelFlow(GeneratorType const GeneratorType, // type of Generator - std::string const &EP_UNUSED(GeneratorName), // user specified name of Generator - int const GeneratorNum, // Generator number - bool const EP_UNUSED(RunFlag), // TRUE when Generator operating - Real64 const FuelFlowRequest, // Generator demand mdot kg/ s - Real64 &FuelFlowProvided, // allowed after constraints kg/s - bool &ConstrainedIncreasingMdot, // true if request was altered because of fuel rate of change up - bool &ConstrainedDecreasingMdot // true if request was altered because of fuel rate of change down + void ManageGeneratorFuelFlow(GeneratorType const GeneratorType, // type of Generator + [[maybe_unused]] std::string const &GeneratorName, // user specified name of Generator + int const GeneratorNum, // Generator number + [[maybe_unused]] bool const RunFlag, // TRUE when Generator operating + Real64 const FuelFlowRequest, // Generator demand mdot kg/ s + Real64 &FuelFlowProvided, // allowed after constraints kg/s + bool &ConstrainedIncreasingMdot, // true if request was altered because of fuel rate of change up + bool &ConstrainedDecreasingMdot // true if request was altered because of fuel rate of change down ) { diff --git a/src/EnergyPlus/GroundHeatExchangers.cc b/src/EnergyPlus/GroundHeatExchangers.cc index ff8439df776..38137356d29 100644 --- a/src/EnergyPlus/GroundHeatExchangers.cc +++ b/src/EnergyPlus/GroundHeatExchangers.cc @@ -395,17 +395,18 @@ namespace GroundHeatExchangers { //****************************************************************************** - void GLHEBase::onInitLoopEquip(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation)) + void GLHEBase::onInitLoopEquip(EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation) { this->initGLHESimVars(state); } //****************************************************************************** - void GLHEBase::simulate(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation), - bool const EP_UNUSED(FirstHVACIteration), - Real64 &EP_UNUSED(CurLoad), - bool const EP_UNUSED(RunFlag)) + void GLHEBase::simulate(EnergyPlusData &state, + [[maybe_unused]] const PlantLocation &calledFromLocation, + [[maybe_unused]] bool const FirstHVACIteration, + [[maybe_unused]] Real64 &CurLoad, + [[maybe_unused]] bool const RunFlag) { if (state.dataGlobal->KickOffSimulation) { @@ -1175,7 +1176,7 @@ namespace GroundHeatExchangers { //****************************************************************************** - void GLHESlinky::calcGFunctions(EnergyPlusData &state) + void GLHESlinky::calcGFunctions([[maybe_unused]] EnergyPlusData &state) { // SUBROUTINE INFORMATION: // AUTHOR: Matt Mitchell @@ -1368,7 +1369,7 @@ namespace GroundHeatExchangers { //****************************************************************************** - void GLHESlinky::readCacheFileAndCompareWithThisGLHECache(EnergyPlusData &EP_UNUSED(state)) + void GLHESlinky::readCacheFileAndCompareWithThisGLHECache([[maybe_unused]] EnergyPlusData &state) { } diff --git a/src/EnergyPlus/GroundHeatExchangers.hh b/src/EnergyPlus/GroundHeatExchangers.hh index 0c2c5ed7168..8b0be3c34bc 100644 --- a/src/EnergyPlus/GroundHeatExchangers.hh +++ b/src/EnergyPlus/GroundHeatExchangers.hh @@ -288,9 +288,9 @@ namespace GroundHeatExchangers { virtual void readCacheFileAndCompareWithThisGLHECache(EnergyPlusData &state) = 0; - void onInitLoopEquip(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation) override; + void onInitLoopEquip([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation) override; - void simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, bool const FirstHVACIteration, Real64 &CurLoad, + void simulate([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, bool const FirstHVACIteration, Real64 &CurLoad, bool const RunFlag) override; static PlantComponent *factory(EnergyPlusData &state, int const objectType, std::string objectName); diff --git a/src/EnergyPlus/GroundTemperatureModeling/SiteBuildingSurfaceGroundTemperatures.cc b/src/EnergyPlus/GroundTemperatureModeling/SiteBuildingSurfaceGroundTemperatures.cc index 702dc9d9f13..597f25e4167 100644 --- a/src/EnergyPlus/GroundTemperatureModeling/SiteBuildingSurfaceGroundTemperatures.cc +++ b/src/EnergyPlus/GroundTemperatureModeling/SiteBuildingSurfaceGroundTemperatures.cc @@ -141,7 +141,7 @@ SiteBuildingSurfaceGroundTemps::BuildingSurfaceGTMFactory(EnergyPlusData &state, //****************************************************************************** -Real64 SiteBuildingSurfaceGroundTemps::getGroundTemp(EnergyPlusData &EP_UNUSED(state)) +Real64 SiteBuildingSurfaceGroundTemps::getGroundTemp([[maybe_unused]] EnergyPlusData &state) { // SUBROUTINE INFORMATION: // AUTHOR Matt Mitchell @@ -157,7 +157,8 @@ Real64 SiteBuildingSurfaceGroundTemps::getGroundTemp(EnergyPlusData &EP_UNUSED(s //****************************************************************************** -Real64 SiteBuildingSurfaceGroundTemps::getGroundTempAtTimeInSeconds(EnergyPlusData &state, Real64 const EP_UNUSED(_depth), Real64 const _seconds) +Real64 +SiteBuildingSurfaceGroundTemps::getGroundTempAtTimeInSeconds(EnergyPlusData &state, [[maybe_unused]] Real64 const _depth, Real64 const _seconds) { // SUBROUTINE INFORMATION: // AUTHOR Matt Mitchell @@ -187,7 +188,7 @@ Real64 SiteBuildingSurfaceGroundTemps::getGroundTempAtTimeInSeconds(EnergyPlusDa //****************************************************************************** -Real64 SiteBuildingSurfaceGroundTemps::getGroundTempAtTimeInMonths(EnergyPlusData &state, Real64 const EP_UNUSED(_depth), int const _month) +Real64 SiteBuildingSurfaceGroundTemps::getGroundTempAtTimeInMonths(EnergyPlusData &state, [[maybe_unused]] Real64 const _depth, int const _month) { // SUBROUTINE INFORMATION: // AUTHOR Matt Mitchell diff --git a/src/EnergyPlus/GroundTemperatureModeling/SiteDeepGroundTemperatures.cc b/src/EnergyPlus/GroundTemperatureModeling/SiteDeepGroundTemperatures.cc index 4b3485d5078..51ed157e7ec 100644 --- a/src/EnergyPlus/GroundTemperatureModeling/SiteDeepGroundTemperatures.cc +++ b/src/EnergyPlus/GroundTemperatureModeling/SiteDeepGroundTemperatures.cc @@ -134,7 +134,7 @@ std::shared_ptr SiteDeepGroundTemps::DeepGTMFactory(EnergyP //****************************************************************************** -Real64 SiteDeepGroundTemps::getGroundTemp(EnergyPlusData &EP_UNUSED(state)) +Real64 SiteDeepGroundTemps::getGroundTemp([[maybe_unused]] EnergyPlusData &state) { // SUBROUTINE INFORMATION: // AUTHOR Matt Mitchell @@ -150,7 +150,7 @@ Real64 SiteDeepGroundTemps::getGroundTemp(EnergyPlusData &EP_UNUSED(state)) //****************************************************************************** -Real64 SiteDeepGroundTemps::getGroundTempAtTimeInSeconds(EnergyPlusData &state, Real64 const EP_UNUSED(_depth), Real64 const _seconds) +Real64 SiteDeepGroundTemps::getGroundTempAtTimeInSeconds(EnergyPlusData &state, [[maybe_unused]] Real64 const _depth, Real64 const _seconds) { // SUBROUTINE INFORMATION: // AUTHOR Matt Mitchell @@ -180,7 +180,7 @@ Real64 SiteDeepGroundTemps::getGroundTempAtTimeInSeconds(EnergyPlusData &state, //****************************************************************************** -Real64 SiteDeepGroundTemps::getGroundTempAtTimeInMonths(EnergyPlusData &state, Real64 const EP_UNUSED(_depth), int const _month) +Real64 SiteDeepGroundTemps::getGroundTempAtTimeInMonths(EnergyPlusData &state, [[maybe_unused]] Real64 const _depth, int const _month) { // SUBROUTINE INFORMATION: // AUTHOR Matt Mitchell diff --git a/src/EnergyPlus/GroundTemperatureModeling/SiteDeepGroundTemperatures.hh b/src/EnergyPlus/GroundTemperatureModeling/SiteDeepGroundTemperatures.hh index 0ab7542dac1..dad5c73554d 100644 --- a/src/EnergyPlus/GroundTemperatureModeling/SiteDeepGroundTemperatures.hh +++ b/src/EnergyPlus/GroundTemperatureModeling/SiteDeepGroundTemperatures.hh @@ -78,7 +78,7 @@ public: static std::shared_ptr DeepGTMFactory(EnergyPlusData &state, int objectType, std::string objectName); - Real64 getGroundTemp(EnergyPlusData &EP_UNUSED(state)) override; + Real64 getGroundTemp([[maybe_unused]] EnergyPlusData &state) override; Real64 getGroundTempAtTimeInSeconds(EnergyPlusData &state, Real64 const depth, Real64 const timeInSecondsOfSim) override; diff --git a/src/EnergyPlus/GroundTemperatureModeling/SiteFCFactorMethodGroundTemperatures.cc b/src/EnergyPlus/GroundTemperatureModeling/SiteFCFactorMethodGroundTemperatures.cc index 447860964e8..a8beb5974cb 100644 --- a/src/EnergyPlus/GroundTemperatureModeling/SiteFCFactorMethodGroundTemperatures.cc +++ b/src/EnergyPlus/GroundTemperatureModeling/SiteFCFactorMethodGroundTemperatures.cc @@ -149,7 +149,7 @@ SiteFCFactorMethodGroundTemps::FCFactorGTMFactory(EnergyPlusData &state, int obj //****************************************************************************** -Real64 SiteFCFactorMethodGroundTemps::getGroundTemp(EnergyPlusData &EP_UNUSED(state)) +Real64 SiteFCFactorMethodGroundTemps::getGroundTemp([[maybe_unused]] EnergyPlusData &state) { // SUBROUTINE INFORMATION: // AUTHOR Matt Mitchell @@ -165,7 +165,7 @@ Real64 SiteFCFactorMethodGroundTemps::getGroundTemp(EnergyPlusData &EP_UNUSED(st //****************************************************************************** -Real64 SiteFCFactorMethodGroundTemps::getGroundTempAtTimeInSeconds(EnergyPlusData &state, Real64 const EP_UNUSED(_depth), Real64 const _seconds) +Real64 SiteFCFactorMethodGroundTemps::getGroundTempAtTimeInSeconds(EnergyPlusData &state, [[maybe_unused]] Real64 const _depth, Real64 const _seconds) { // SUBROUTINE INFORMATION: // AUTHOR Matt Mitchell @@ -195,7 +195,7 @@ Real64 SiteFCFactorMethodGroundTemps::getGroundTempAtTimeInSeconds(EnergyPlusDat //****************************************************************************** -Real64 SiteFCFactorMethodGroundTemps::getGroundTempAtTimeInMonths(EnergyPlusData &state, Real64 const EP_UNUSED(_depth), int const _month) +Real64 SiteFCFactorMethodGroundTemps::getGroundTempAtTimeInMonths(EnergyPlusData &state, [[maybe_unused]] Real64 const _depth, int const _month) { // SUBROUTINE INFORMATION: // AUTHOR Matt Mitchell diff --git a/src/EnergyPlus/GroundTemperatureModeling/SiteFCFactorMethodGroundTemperatures.hh b/src/EnergyPlus/GroundTemperatureModeling/SiteFCFactorMethodGroundTemperatures.hh index 8622aba5d9a..a16ee9d657a 100644 --- a/src/EnergyPlus/GroundTemperatureModeling/SiteFCFactorMethodGroundTemperatures.hh +++ b/src/EnergyPlus/GroundTemperatureModeling/SiteFCFactorMethodGroundTemperatures.hh @@ -78,7 +78,7 @@ public: static std::shared_ptr FCFactorGTMFactory(EnergyPlusData &state, int objectType, std::string objectName); - Real64 getGroundTemp(EnergyPlusData &EP_UNUSED(state)) override; + Real64 getGroundTemp([[maybe_unused]] EnergyPlusData &state) override; Real64 getGroundTempAtTimeInSeconds(EnergyPlusData &state, Real64 const depth, Real64 const timeInSecondsOfSim) override; diff --git a/src/EnergyPlus/GroundTemperatureModeling/SiteShallowGroundTemperatures.cc b/src/EnergyPlus/GroundTemperatureModeling/SiteShallowGroundTemperatures.cc index 3c55ba086bd..917a3bfe248 100644 --- a/src/EnergyPlus/GroundTemperatureModeling/SiteShallowGroundTemperatures.cc +++ b/src/EnergyPlus/GroundTemperatureModeling/SiteShallowGroundTemperatures.cc @@ -133,7 +133,7 @@ std::shared_ptr SiteShallowGroundTemps::ShallowGTMFactor //****************************************************************************** -Real64 SiteShallowGroundTemps::getGroundTemp(EnergyPlusData &EP_UNUSED(state)) +Real64 SiteShallowGroundTemps::getGroundTemp([[maybe_unused]] EnergyPlusData &state) { // SUBROUTINE INFORMATION: // AUTHOR Matt Mitchell @@ -149,7 +149,7 @@ Real64 SiteShallowGroundTemps::getGroundTemp(EnergyPlusData &EP_UNUSED(state)) //****************************************************************************** -Real64 SiteShallowGroundTemps::getGroundTempAtTimeInSeconds(EnergyPlusData& state, Real64 const EP_UNUSED(_depth), Real64 const _seconds) +Real64 SiteShallowGroundTemps::getGroundTempAtTimeInSeconds(EnergyPlusData &state, [[maybe_unused]] Real64 const _depth, Real64 const _seconds) { // SUBROUTINE INFORMATION: // AUTHOR Matt Mitchell @@ -179,7 +179,7 @@ Real64 SiteShallowGroundTemps::getGroundTempAtTimeInSeconds(EnergyPlusData& stat //****************************************************************************** -Real64 SiteShallowGroundTemps::getGroundTempAtTimeInMonths(EnergyPlusData &state, Real64 const EP_UNUSED(_depth), int const _month) +Real64 SiteShallowGroundTemps::getGroundTempAtTimeInMonths(EnergyPlusData &state, [[maybe_unused]] Real64 const _depth, int const _month) { // SUBROUTINE INFORMATION: // AUTHOR Matt Mitchell diff --git a/src/EnergyPlus/GroundTemperatureModeling/SiteShallowGroundTemperatures.hh b/src/EnergyPlus/GroundTemperatureModeling/SiteShallowGroundTemperatures.hh index 3f42d8b32c4..fa4106871a3 100644 --- a/src/EnergyPlus/GroundTemperatureModeling/SiteShallowGroundTemperatures.hh +++ b/src/EnergyPlus/GroundTemperatureModeling/SiteShallowGroundTemperatures.hh @@ -80,7 +80,7 @@ public: static std::shared_ptr ShallowGTMFactory(EnergyPlusData &state, int objectType, std::string objectName); - Real64 getGroundTemp(EnergyPlusData &EP_UNUSED(state)) override; + Real64 getGroundTemp([[maybe_unused]] EnergyPlusData &state) override; Real64 getGroundTempAtTimeInSeconds(EnergyPlusData &state, Real64 const depth, Real64 const timeInSecondsOfSim) override; diff --git a/src/EnergyPlus/HVACCooledBeam.cc b/src/EnergyPlus/HVACCooledBeam.cc index 6ec12cce870..b4a92aad20c 100644 --- a/src/EnergyPlus/HVACCooledBeam.cc +++ b/src/EnergyPlus/HVACCooledBeam.cc @@ -905,11 +905,11 @@ namespace HVACCooledBeam { } void ControlCoolBeam(EnergyPlusData &state, - int const CBNum, // number of the current unit being simulated - int const ZoneNum, // number of zone being served - int const ZoneNodeNum, // zone node number - bool const EP_UNUSED(FirstHVACIteration), // TRUE if 1st HVAC simulation of system timestep - Real64 &NonAirSysOutput // convective cooling by the beam system [W] + int const CBNum, // number of the current unit being simulated + int const ZoneNum, // number of zone being served + int const ZoneNodeNum, // zone node number + [[maybe_unused]] bool const FirstHVACIteration, // TRUE if 1st HVAC simulation of system timestep + Real64 &NonAirSysOutput // convective cooling by the beam system [W] ) { diff --git a/src/EnergyPlus/HVACDXSystem.cc b/src/EnergyPlus/HVACDXSystem.cc index 884bb38f6be..7dc55b80bd5 100644 --- a/src/EnergyPlus/HVACDXSystem.cc +++ b/src/EnergyPlus/HVACDXSystem.cc @@ -3508,7 +3508,11 @@ namespace HVACDXSystem { } void GetCoolingCoilTypeNameAndIndex(EnergyPlusData &state, - std::string const &DXCoilSysName, int &CoolCoilType, int &CoolCoilIndex, std::string &CoolCoilName, bool &EP_UNUSED(ErrFound)) + std::string const &DXCoilSysName, + int &CoolCoilType, + int &CoolCoilIndex, + std::string &CoolCoilName, + [[maybe_unused]] bool &ErrFound) { // SUBROUTINE INFORMATION: // AUTHOR Richard Raustad, FSEC diff --git a/src/EnergyPlus/HVACDuct.cc b/src/EnergyPlus/HVACDuct.cc index 2046a2f2b9c..bdf4da7dcc8 100644 --- a/src/EnergyPlus/HVACDuct.cc +++ b/src/EnergyPlus/HVACDuct.cc @@ -123,9 +123,9 @@ namespace HVACDuct { // Functions void SimDuct(EnergyPlusData &state, - std::string const &CompName, // name of the duct component - bool const EP_UNUSED(FirstHVACIteration), // TRUE if 1st HVAC simulation of system timestep !unused1208 - int &CompIndex // index of duct component + std::string const &CompName, // name of the duct component + [[maybe_unused]] bool const FirstHVACIteration, // TRUE if 1st HVAC simulation of system timestep !unused1208 + int &CompIndex // index of duct component ) { @@ -299,7 +299,7 @@ namespace HVACDuct { // do these initializations every HVAC time step } - void CalcDuct(int const EP_UNUSED(DuctNum)) // number of the current duct being simulated !unused1208 + void CalcDuct([[maybe_unused]] int const DuctNum) // number of the current duct being simulated !unused1208 { // SUBROUTINE INFORMATION: @@ -396,7 +396,7 @@ namespace HVACDuct { } } - void ReportDuct(int const EP_UNUSED(DuctNum)) // number of the current duct being simulated !unused1208 + void ReportDuct([[maybe_unused]] int const DuctNum) // number of the current duct being simulated !unused1208 { // SUBROUTINE INFORMATION: diff --git a/src/EnergyPlus/HVACFourPipeBeam.cc b/src/EnergyPlus/HVACFourPipeBeam.cc index 7418ee71e1b..a87a7dddaf7 100644 --- a/src/EnergyPlus/HVACFourPipeBeam.cc +++ b/src/EnergyPlus/HVACFourPipeBeam.cc @@ -1075,8 +1075,8 @@ namespace FourPipeBeam { } void HVACFourPipeBeam::control(EnergyPlusData &state, - bool const EP_UNUSED(FirstHVACIteration), // TRUE if 1st HVAC simulation of system timestep - Real64 &NonAirSysOutput // convective cooling by the beam system [W] + [[maybe_unused]] bool const FirstHVACIteration, // TRUE if 1st HVAC simulation of system timestep + Real64 &NonAirSysOutput // convective cooling by the beam system [W] ) { diff --git a/src/EnergyPlus/HVACHXAssistedCoolingCoil.cc b/src/EnergyPlus/HVACHXAssistedCoolingCoil.cc index 0f643740dd4..d2407836e55 100644 --- a/src/EnergyPlus/HVACHXAssistedCoolingCoil.cc +++ b/src/EnergyPlus/HVACHXAssistedCoolingCoil.cc @@ -1055,7 +1055,8 @@ namespace HVACHXAssistedCoolingCoil { } } - void CheckHXAssistedCoolingCoilSchedule(EnergyPlusData &state, std::string const &EP_UNUSED(CompType), // unused1208 + void CheckHXAssistedCoolingCoilSchedule(EnergyPlusData &state, + [[maybe_unused]] std::string const &CompType, // unused1208 std::string const &CompName, Real64 &Value, int &CompIndex) diff --git a/src/EnergyPlus/HVACVariableRefrigerantFlow.cc b/src/EnergyPlus/HVACVariableRefrigerantFlow.cc index ccda76eff52..92336caab58 100644 --- a/src/EnergyPlus/HVACVariableRefrigerantFlow.cc +++ b/src/EnergyPlus/HVACVariableRefrigerantFlow.cc @@ -407,13 +407,16 @@ namespace HVACVariableRefrigerantFlow { return nullptr; // LCOV_EXCL_LINE } - void VRFCondenserEquipment::onInitLoopEquip(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation)) + void VRFCondenserEquipment::onInitLoopEquip(EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation) { this->SizeVRFCondenser(state); } - void - VRFCondenserEquipment::getDesignCapacities(EnergyPlusData &EP_UNUSED(state), const PlantLocation &EP_UNUSED(calledFromLocation), Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) + void VRFCondenserEquipment::getDesignCapacities([[maybe_unused]] EnergyPlusData &state, + [[maybe_unused]] const PlantLocation &calledFromLocation, + Real64 &MaxLoad, + Real64 &MinLoad, + Real64 &OptLoad) { MinLoad = 0.0; MaxLoad = max(this->CoolingCapacity, this->HeatingCapacity); // greater of cooling and heating capacity @@ -424,8 +427,8 @@ namespace HVACVariableRefrigerantFlow { void VRFCondenserEquipment::simulate(EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, - Real64 &EP_UNUSED(CurLoad), - bool EP_UNUSED(RunFlag)) + [[maybe_unused]] Real64 &CurLoad, + [[maybe_unused]] bool RunFlag) { if (calledFromLocation.loopNum == this->SourceLoopNum) { // condenser loop PlantUtilities::UpdateChillerComponentCondenserSide(state, this->SourceLoopNum, diff --git a/src/EnergyPlus/HVACVariableRefrigerantFlow.hh b/src/EnergyPlus/HVACVariableRefrigerantFlow.hh index cb8281580a8..eb5ccaf1969 100644 --- a/src/EnergyPlus/HVACVariableRefrigerantFlow.hh +++ b/src/EnergyPlus/HVACVariableRefrigerantFlow.hh @@ -431,11 +431,11 @@ namespace HVACVariableRefrigerantFlow { // Begin of Methods for New VRF Model: Fluid Temperature Control //****************************************************************************** - void onInitLoopEquip(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation) override; + void onInitLoopEquip([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation) override; void getDesignCapacities(EnergyPlusData &state, const PlantLocation &calledFromLocation, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) override; - void simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; + void simulate([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; static PlantComponent *factory(EnergyPlusData &state, std::string const &objectName); diff --git a/src/EnergyPlus/HWBaseboardRadiator.cc b/src/EnergyPlus/HWBaseboardRadiator.cc index 3f03c3e53d6..77fbb117b3b 100644 --- a/src/EnergyPlus/HWBaseboardRadiator.cc +++ b/src/EnergyPlus/HWBaseboardRadiator.cc @@ -1757,13 +1757,13 @@ namespace HWBaseboardRadiator { } void UpdateHWBaseboardPlantConnection(EnergyPlusData &state, - int const BaseboardTypeNum, // type index - std::string const &BaseboardName, // component name - int const EP_UNUSED(EquipFlowCtrl), // Flow control mode for the equipment - int const EP_UNUSED(LoopNum), // Plant loop index for where called from - int const EP_UNUSED(LoopSide), // Plant loop side index for where called from - int &CompIndex, // Chiller number pointer - bool const EP_UNUSED(FirstHVACIteration), + int const BaseboardTypeNum, // type index + std::string const &BaseboardName, // component name + [[maybe_unused]] int const EquipFlowCtrl, // Flow control mode for the equipment + [[maybe_unused]] int const LoopNum, // Plant loop index for where called from + [[maybe_unused]] int const LoopSide, // Plant loop side index for where called from + int &CompIndex, // Chiller number pointer + [[maybe_unused]] bool const FirstHVACIteration, bool &InitLoopEquip // If not zero, calculate the max load for operating conditions ) { diff --git a/src/EnergyPlus/HeatBalFiniteDiffManager.cc b/src/EnergyPlus/HeatBalFiniteDiffManager.cc index 86b4e147b3f..cad628295e8 100644 --- a/src/EnergyPlus/HeatBalFiniteDiffManager.cc +++ b/src/EnergyPlus/HeatBalFiniteDiffManager.cc @@ -1383,21 +1383,21 @@ namespace HeatBalFiniteDiffManager { } void ExteriorBCEqns(EnergyPlusData &state, - int const Delt, // Time Increment - int const i, // Node Index - int const Lay, // Layer Number for Construction - int const Surf, // Surface number - Array1D const &EP_UNUSED(T), // Old node Temperature in MFD finite difference solution - Array1D &TT, // New node Temperature in MFD finite difference solution. - Array1D const &EP_UNUSED(Rhov), // MFD Nodal Vapor Density[kg/m3] and is the old or last time step result. - Array1D &RhoT, // MFD vapor density for the new time step. - Array1D &EP_UNUSED(RH), // Nodal relative humidity - Array1D const &TD, // The old dry Temperature at each node for the CondFD algorithm.. - Array1D &TDT, // The current or new Temperature at each node location for the CondFD solution.. - Array1D &EnthOld, // Old Nodal enthalpy - Array1D &EnthNew, // New Nodal enthalpy - int const TotNodes, // Total nodes in layer - Real64 const HMovInsul // Conductance of movable(transparent) insulation. + int const Delt, // Time Increment + int const i, // Node Index + int const Lay, // Layer Number for Construction + int const Surf, // Surface number + [[maybe_unused]] Array1D const &T, // Old node Temperature in MFD finite difference solution + Array1D &TT, // New node Temperature in MFD finite difference solution. + [[maybe_unused]] Array1D const &Rhov, // MFD Nodal Vapor Density[kg/m3] and is the old or last time step result. + Array1D &RhoT, // MFD vapor density for the new time step. + [[maybe_unused]] Array1D &RH, // Nodal relative humidity + Array1D const &TD, // The old dry Temperature at each node for the CondFD algorithm.. + Array1D &TDT, // The current or new Temperature at each node location for the CondFD solution.. + Array1D &EnthOld, // Old Nodal enthalpy + Array1D &EnthNew, // New Nodal enthalpy + int const TotNodes, // Total nodes in layer + Real64 const HMovInsul // Conductance of movable(transparent) insulation. ) { @@ -1656,19 +1656,19 @@ namespace HeatBalFiniteDiffManager { } void InteriorNodeEqns(EnergyPlusData &state, - int const Delt, // Time Increment - int const i, // Node Index - int const Lay, // Layer Number for Construction - int const Surf, // Surface number - Array1D const &EP_UNUSED(T), // INSIDE SURFACE TEMPERATURE OF EACH HEAT TRANSFER SURF. - Array1D &EP_UNUSED(TT), // INSIDE SURFACE TEMPERATURE OF EACH HEAT TRANSFER SURF. - Array1D const &EP_UNUSED(Rhov), // INSIDE SURFACE TEMPERATURE OF EACH HEAT TRANSFER SURF. - Array1D &EP_UNUSED(RhoT), // INSIDE SURFACE TEMPERATURE OF EACH HEAT TRANSFER SURF. - Array1D &EP_UNUSED(RH), // INSIDE SURFACE TEMPERATURE OF EACH HEAT TRANSFER SURF. - Array1D const &TD, // INSIDE SURFACE TEMPERATURE OF EACH HEAT TRANSFER SURF. - Array1D &TDT, // INSIDE SURFACE TEMPERATURE OF EACH HEAT TRANSFER SURF. - Array1D &EnthOld, // Old Nodal enthalpy - Array1D &EnthNew // New Nodal enthalpy + int const Delt, // Time Increment + int const i, // Node Index + int const Lay, // Layer Number for Construction + int const Surf, // Surface number + [[maybe_unused]] Array1D const &T, // INSIDE SURFACE TEMPERATURE OF EACH HEAT TRANSFER SURF. + [[maybe_unused]] Array1D &TT, // INSIDE SURFACE TEMPERATURE OF EACH HEAT TRANSFER SURF. + [[maybe_unused]] Array1D const &Rhov, // INSIDE SURFACE TEMPERATURE OF EACH HEAT TRANSFER SURF. + [[maybe_unused]] Array1D &RhoT, // INSIDE SURFACE TEMPERATURE OF EACH HEAT TRANSFER SURF. + [[maybe_unused]] Array1D &RH, // INSIDE SURFACE TEMPERATURE OF EACH HEAT TRANSFER SURF. + Array1D const &TD, // INSIDE SURFACE TEMPERATURE OF EACH HEAT TRANSFER SURF. + Array1D &TDT, // INSIDE SURFACE TEMPERATURE OF EACH HEAT TRANSFER SURF. + Array1D &EnthOld, // Old Nodal enthalpy + Array1D &EnthNew // New Nodal enthalpy ) { @@ -1755,20 +1755,20 @@ namespace HeatBalFiniteDiffManager { } void IntInterfaceNodeEqns(EnergyPlusData &state, - int const Delt, // Time Increment - int const i, // Node Index - int const Lay, // Layer Number for Construction - int const Surf, // Surface number - Array1D const &EP_UNUSED(T), // INSIDE SURFACE TEMPERATURE OF EACH HEAT TRANSFER SURF. - Array1D &EP_UNUSED(TT), // INSIDE SURFACE TEMPERATURE OF EACH HEAT TRANSFER SURF. - Array1D const &EP_UNUSED(Rhov), // INSIDE SURFACE TEMPERATURE OF EACH HEAT TRANSFER SURF. - Array1D &EP_UNUSED(RhoT), // INSIDE SURFACE TEMPERATURE OF EACH HEAT TRANSFER SURF. - Array1D &EP_UNUSED(RH), // RELATIVE HUMIDITY. - Array1D const &TD, // OLD NODE TEMPERATURES OF EACH HEAT TRANSFER SURF IN CONDFD. - Array1D &TDT, // NEW NODE TEMPERATURES OF EACH HEAT TRANSFER SURF IN CONDFD. - Array1D const &EP_UNUSED(EnthOld), // Old Nodal enthalpy - Array1D &EnthNew, // New Nodal enthalpy - int const EP_UNUSED(GSiter) // Iteration number of Gauss Seidel iteration + int const Delt, // Time Increment + int const i, // Node Index + int const Lay, // Layer Number for Construction + int const Surf, // Surface number + [[maybe_unused]] Array1D const &T, // INSIDE SURFACE TEMPERATURE OF EACH HEAT TRANSFER SURF. + [[maybe_unused]] Array1D &TT, // INSIDE SURFACE TEMPERATURE OF EACH HEAT TRANSFER SURF. + [[maybe_unused]] Array1D const &Rhov, // INSIDE SURFACE TEMPERATURE OF EACH HEAT TRANSFER SURF. + [[maybe_unused]] Array1D &RhoT, // INSIDE SURFACE TEMPERATURE OF EACH HEAT TRANSFER SURF. + [[maybe_unused]] Array1D &RH, // RELATIVE HUMIDITY. + Array1D const &TD, // OLD NODE TEMPERATURES OF EACH HEAT TRANSFER SURF IN CONDFD. + Array1D &TDT, // NEW NODE TEMPERATURES OF EACH HEAT TRANSFER SURF IN CONDFD. + [[maybe_unused]] Array1D const &EnthOld, // Old Nodal enthalpy + Array1D &EnthNew, // New Nodal enthalpy + [[maybe_unused]] int const GSiter // Iteration number of Gauss Seidel iteration ) { @@ -2048,20 +2048,20 @@ namespace HeatBalFiniteDiffManager { } void InteriorBCEqns(EnergyPlusData &state, - int const Delt, // Time Increment - int const i, // Node Index - int const Lay, // Layer Number for Construction - int const Surf, // Surface number - Array1D const &EP_UNUSED(T), // INSIDE SURFACE TEMPERATURE OF EACH HEAT TRANSFER SURF (Old). - Array1D &EP_UNUSED(TT), // INSIDE SURFACE TEMPERATURE OF EACH HEAT TRANSFER SURF (New). - Array1D const &EP_UNUSED(Rhov), // INSIDE SURFACE TEMPERATURE OF EACH HEAT TRANSFER SURF. - Array1D &EP_UNUSED(RhoT), // INSIDE SURFACE TEMPERATURE OF EACH HEAT TRANSFER SURF. - Array1D &EP_UNUSED(RH), // INSIDE SURFACE TEMPERATURE OF EACH HEAT TRANSFER SURF. - Array1D const &TD, // INSIDE SURFACE TEMPERATURE OF EACH HEAT TRANSFER SURF. - Array1D &TDT, // INSIDE SURFACE TEMPERATURE OF EACH HEAT TRANSFER SURF. - Array1D &EnthOld, // Old Nodal enthalpy - Array1D &EnthNew, // New Nodal enthalpy - Array1D &TDreport // Temperature value from previous HeatSurfaceHeatManager iteration's value + int const Delt, // Time Increment + int const i, // Node Index + int const Lay, // Layer Number for Construction + int const Surf, // Surface number + [[maybe_unused]] Array1D const &T, // INSIDE SURFACE TEMPERATURE OF EACH HEAT TRANSFER SURF (Old). + [[maybe_unused]] Array1D &TT, // INSIDE SURFACE TEMPERATURE OF EACH HEAT TRANSFER SURF (New). + [[maybe_unused]] Array1D const &Rhov, // INSIDE SURFACE TEMPERATURE OF EACH HEAT TRANSFER SURF. + [[maybe_unused]] Array1D &RhoT, // INSIDE SURFACE TEMPERATURE OF EACH HEAT TRANSFER SURF. + [[maybe_unused]] Array1D &RH, // INSIDE SURFACE TEMPERATURE OF EACH HEAT TRANSFER SURF. + Array1D const &TD, // INSIDE SURFACE TEMPERATURE OF EACH HEAT TRANSFER SURF. + Array1D &TDT, // INSIDE SURFACE TEMPERATURE OF EACH HEAT TRANSFER SURF. + Array1D &EnthOld, // Old Nodal enthalpy + Array1D &EnthNew, // New Nodal enthalpy + Array1D &TDreport // Temperature value from previous HeatSurfaceHeatManager iteration's value ) { // SUBROUTINE INFORMATION: diff --git a/src/EnergyPlus/HeatBalanceIntRadExchange.cc b/src/EnergyPlus/HeatBalanceIntRadExchange.cc index 71a958e30e8..56bfd68ea1c 100644 --- a/src/EnergyPlus/HeatBalanceIntRadExchange.cc +++ b/src/EnergyPlus/HeatBalanceIntRadExchange.cc @@ -141,7 +141,7 @@ namespace HeatBalanceIntRadExchange { #ifdef EP_Count_Calls std::string const &CalledFrom) #else - std::string const &EP_UNUSED(CalledFrom)) + [[maybe_unused]] std::string const &CalledFrom) #endif { @@ -1102,12 +1102,12 @@ namespace HeatBalanceIntRadExchange { } void GetInputViewFactors(EnergyPlusData &state, - std::string const &ZoneName, // Needed to check for user input view factors. - int const N, // NUMBER OF SURFACES - Array2A F, // USER INPUT DIRECT VIEW FACTOR MATRIX (N X N) - const Array1D_int &EP_UNUSED(SPtr), // pointer to actual surface number - bool &NoUserInputF, // Flag signifying no input F's for this - bool &ErrorsFound // True when errors are found in number of fields vs max args + std::string const &ZoneName, // Needed to check for user input view factors. + int const N, // NUMBER OF SURFACES + Array2A F, // USER INPUT DIRECT VIEW FACTOR MATRIX (N X N) + [[maybe_unused]] const Array1D_int &SPtr, // pointer to actual surface number + bool &NoUserInputF, // Flag signifying no input F's for this + bool &ErrorsFound // True when errors are found in number of fields vs max args ) { diff --git a/src/EnergyPlus/HeatBalanceManager.cc b/src/EnergyPlus/HeatBalanceManager.cc index 7b991bafc62..c31ae8b0613 100644 --- a/src/EnergyPlus/HeatBalanceManager.cc +++ b/src/EnergyPlus/HeatBalanceManager.cc @@ -5039,11 +5039,11 @@ namespace HeatBalanceManager { int &NumAlphas, Array1D const &rNumericArgs, int &NumNumbers, - Array1D_bool const &EP_UNUSED(lNumericFieldBlanks), // Unused + [[maybe_unused]] Array1D_bool const &lNumericFieldBlanks, // Unused Array1D_bool const &lAlphaFieldBlanks, Array1D_string const &cAlphaFieldNames, - Array1D_string const &EP_UNUSED(cNumericFieldNames), // Unused - bool &ErrorsFound // If errors found in input + [[maybe_unused]] Array1D_string const &cNumericFieldNames, // Unused + bool &ErrorsFound // If errors found in input ) { @@ -7808,7 +7808,7 @@ namespace HeatBalanceManager { } } - void CreateTCConstructions(EnergyPlusData &state, bool &EP_UNUSED(ErrorsFound)) // If errors found in input + void CreateTCConstructions(EnergyPlusData &state, [[maybe_unused]] bool &ErrorsFound) // If errors found in input { // SUBROUTINE INFORMATION: diff --git a/src/EnergyPlus/HeatPumpWaterToWaterCOOLING.cc b/src/EnergyPlus/HeatPumpWaterToWaterCOOLING.cc index de5662664b1..31ff00bacb9 100644 --- a/src/EnergyPlus/HeatPumpWaterToWaterCOOLING.cc +++ b/src/EnergyPlus/HeatPumpWaterToWaterCOOLING.cc @@ -126,8 +126,9 @@ namespace HeatPumpWaterToWaterCOOLING { return nullptr; // LCOV_EXCL_LINE } - void GshpPeCoolingSpecs::simulate(EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, - bool EP_UNUSED(RunFlag)) { + void GshpPeCoolingSpecs::simulate( + EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, [[maybe_unused]] bool RunFlag) + { // Simulate the model for the Demand "MyLoad" if (calledFromLocation.loopNum == this->LoadLoopNum) { // chilled water loop this->initialize(state); @@ -149,8 +150,8 @@ namespace HeatPumpWaterToWaterCOOLING { } } - void GshpPeCoolingSpecs::getDesignCapacities(EnergyPlusData &EP_UNUSED(state), - const PlantLocation &EP_UNUSED(calledFromLocation), + void GshpPeCoolingSpecs::getDesignCapacities([[maybe_unused]] EnergyPlusData &state, + [[maybe_unused]] const PlantLocation &calledFromLocation, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) @@ -160,7 +161,8 @@ namespace HeatPumpWaterToWaterCOOLING { OptLoad = this->NomCap * this->OptPartLoadRat; } - void GshpPeCoolingSpecs::onInitLoopEquip(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation)) { + void GshpPeCoolingSpecs::onInitLoopEquip(EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation) + { if (this->plantScanFlag) { // Locate the heating on the plant loops for later usage bool errFlag = false; diff --git a/src/EnergyPlus/HeatPumpWaterToWaterCOOLING.hh b/src/EnergyPlus/HeatPumpWaterToWaterCOOLING.hh index a95aea45dc3..4fec983b09a 100644 --- a/src/EnergyPlus/HeatPumpWaterToWaterCOOLING.hh +++ b/src/EnergyPlus/HeatPumpWaterToWaterCOOLING.hh @@ -155,7 +155,7 @@ namespace HeatPumpWaterToWaterCOOLING { static PlantComponent *factory(EnergyPlusData &state, const std::string& objectName); - void simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, + void simulate([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; void getDesignCapacities(EnergyPlusData &state, @@ -164,7 +164,7 @@ namespace HeatPumpWaterToWaterCOOLING { Real64 &MinLoad, Real64 &OptLoad) override; - void onInitLoopEquip(EnergyPlusData &EP_UNUSED(state), const PlantLocation &EP_UNUSED(calledFromLocation)) override; + void onInitLoopEquip([[maybe_unused]] EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation) override; void initialize(EnergyPlusData &state); diff --git a/src/EnergyPlus/HeatPumpWaterToWaterHEATING.cc b/src/EnergyPlus/HeatPumpWaterToWaterHEATING.cc index 5ca484bfe2f..60da32652f8 100644 --- a/src/EnergyPlus/HeatPumpWaterToWaterHEATING.cc +++ b/src/EnergyPlus/HeatPumpWaterToWaterHEATING.cc @@ -128,9 +128,9 @@ namespace HeatPumpWaterToWaterHEATING { return nullptr; // LCOV_EXCL_LINE } - - void GshpPeHeatingSpecs::simulate(EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, - bool EP_UNUSED(RunFlag)) { + void GshpPeHeatingSpecs::simulate( + EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, [[maybe_unused]] bool RunFlag) + { // Simulate the model for the Demand "MyLoad" if (calledFromLocation.loopNum == this->LoadLoopNum) { // chilled water loop @@ -154,17 +154,19 @@ namespace HeatPumpWaterToWaterHEATING { } } - void GshpPeHeatingSpecs::getDesignCapacities(EnergyPlusData &EP_UNUSED(state), - const PlantLocation &EP_UNUSED(calledFromLocation), + void GshpPeHeatingSpecs::getDesignCapacities([[maybe_unused]] EnergyPlusData &state, + [[maybe_unused]] const PlantLocation &calledFromLocation, Real64 &MaxLoad, Real64 &MinLoad, - Real64 &OptLoad) { + Real64 &OptLoad) + { MinLoad = this->NomCap * this->MinPartLoadRat; MaxLoad = this->NomCap * this->MaxPartLoadRat; OptLoad = this->NomCap * this->OptPartLoadRat; } - void GshpPeHeatingSpecs::onInitLoopEquip(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation)) { + void GshpPeHeatingSpecs::onInitLoopEquip(EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation) + { if (this->plantScanFlag) { // Locate the heating on the plant loops for later usage bool errFlag = false; @@ -208,7 +210,6 @@ namespace HeatPumpWaterToWaterHEATING { } } - #pragma clang diagnostic push #pragma ide diagnostic ignored "readability-magic-numbers" void GetGshpInput(EnergyPlusData &state) diff --git a/src/EnergyPlus/HeatPumpWaterToWaterHEATING.hh b/src/EnergyPlus/HeatPumpWaterToWaterHEATING.hh index 096e567de7b..e1938ae5819 100644 --- a/src/EnergyPlus/HeatPumpWaterToWaterHEATING.hh +++ b/src/EnergyPlus/HeatPumpWaterToWaterHEATING.hh @@ -153,7 +153,7 @@ namespace HeatPumpWaterToWaterHEATING { static PlantComponent *factory(EnergyPlusData &state, const std::string& objectName); - void simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, + void simulate([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; void getDesignCapacities(EnergyPlusData &state, @@ -162,7 +162,7 @@ namespace HeatPumpWaterToWaterHEATING { Real64 &MinLoad, Real64 &OptLoad) override; - void onInitLoopEquip(EnergyPlusData &EP_UNUSED(state), const PlantLocation &EP_UNUSED(calledFromLocation)) override; + void onInitLoopEquip([[maybe_unused]] EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation) override; void initialize(EnergyPlusData &state); diff --git a/src/EnergyPlus/HeatPumpWaterToWaterSimple.cc b/src/EnergyPlus/HeatPumpWaterToWaterSimple.cc index 26414e433c9..e08681169d1 100644 --- a/src/EnergyPlus/HeatPumpWaterToWaterSimple.cc +++ b/src/EnergyPlus/HeatPumpWaterToWaterSimple.cc @@ -146,8 +146,11 @@ namespace HeatPumpWaterToWaterSimple { return nullptr; } - void GshpSpecs::simulate( - EnergyPlusData &state, const PlantLocation &calledFromLocation, bool const FirstHVACIteration, Real64 &CurLoad, bool const EP_UNUSED(RunFlag)) + void GshpSpecs::simulate(EnergyPlusData &state, + const PlantLocation &calledFromLocation, + bool const FirstHVACIteration, + Real64 &CurLoad, + [[maybe_unused]] bool const RunFlag) { if (this->WWHPPlantTypeOfNum == DataPlant::TypeOf_HPWaterEFCooling) { if (calledFromLocation.loopNum == this->LoadLoopNum) { // chilled water loop @@ -192,7 +195,7 @@ namespace HeatPumpWaterToWaterSimple { } // TypeOfEquip } - void GshpSpecs::onInitLoopEquip(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation)) + void GshpSpecs::onInitLoopEquip(EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation) { bool initFirstHVAC = true; Real64 initCurLoad = 0.0; @@ -645,9 +648,9 @@ namespace HeatPumpWaterToWaterSimple { } void GshpSpecs::InitWatertoWaterHP(EnergyPlusData &state, - int const GSHPTypeNum, // Type of GSHP - std::string const &EP_UNUSED(GSHPName), // User Specified Name of GSHP - bool const EP_UNUSED(FirstHVACIteration), + int const GSHPTypeNum, // Type of GSHP + [[maybe_unused]] std::string const &GSHPName, // User Specified Name of GSHP + [[maybe_unused]] bool const FirstHVACIteration, Real64 const MyLoad // Demand Load ) { diff --git a/src/EnergyPlus/HeatPumpWaterToWaterSimple.hh b/src/EnergyPlus/HeatPumpWaterToWaterSimple.hh index 36e37d608cf..f8aff02fbda 100644 --- a/src/EnergyPlus/HeatPumpWaterToWaterSimple.hh +++ b/src/EnergyPlus/HeatPumpWaterToWaterSimple.hh @@ -201,7 +201,7 @@ namespace HeatPumpWaterToWaterSimple { static void GetWatertoWaterHPInput(EnergyPlusData &state); - void simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, bool const FirstHVACIteration, Real64 &CurLoad, bool const RunFlag) override; + void simulate([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, bool const FirstHVACIteration, Real64 &CurLoad, bool const RunFlag) override; void getDesignCapacities(EnergyPlusData &state, const PlantLocation &calledFromLocation, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) override; diff --git a/src/EnergyPlus/HeatingCoils.cc b/src/EnergyPlus/HeatingCoils.cc index 6c2eccf30fc..c4f038cc8d9 100644 --- a/src/EnergyPlus/HeatingCoils.cc +++ b/src/EnergyPlus/HeatingCoils.cc @@ -2075,9 +2075,9 @@ namespace HeatingCoils { void CalcFuelHeatingCoil(EnergyPlusData &state, int const CoilNum, // index to heating coil Real64 const QCoilReq, - Real64 &QCoilActual, // coil load actually delivered (W) - int const FanOpMode, // fan operating mode - Real64 const EP_UNUSED(PartLoadRatio) // part-load ratio of heating coil + Real64 &QCoilActual, // coil load actually delivered (W) + int const FanOpMode, // fan operating mode + [[maybe_unused]] Real64 const PartLoadRatio // part-load ratio of heating coil ) { // SUBROUTINE INFORMATION: diff --git a/src/EnergyPlus/HighTempRadiantSystem.cc b/src/EnergyPlus/HighTempRadiantSystem.cc index 851357e7331..1425456f8d5 100644 --- a/src/EnergyPlus/HighTempRadiantSystem.cc +++ b/src/EnergyPlus/HighTempRadiantSystem.cc @@ -974,8 +974,8 @@ namespace HighTempRadiantSystem { void CalcHighTempRadiantSystemSP( EnergyPlusData &state, - bool const EP_UNUSED(FirstHVACIteration), // true if this is the first HVAC iteration at this system time step !unused1208 - int const RadSysNum // name of the low temperature radiant system + [[maybe_unused]] bool const FirstHVACIteration, // true if this is the first HVAC iteration at this system time step !unused1208 + int const RadSysNum // name of the low temperature radiant system ) { diff --git a/src/EnergyPlus/Humidifiers.cc b/src/EnergyPlus/Humidifiers.cc index c51147aa235..4b1fe1a997a 100644 --- a/src/EnergyPlus/Humidifiers.cc +++ b/src/EnergyPlus/Humidifiers.cc @@ -151,9 +151,9 @@ namespace Humidifiers { } void SimHumidifier(EnergyPlusData &state, - std::string const &CompName, // name of the humidifier unit - bool const EP_UNUSED(FirstHVACIteration), // TRUE if 1st HVAC simulation of system timestep - int &CompIndex // Pointer to Humidifier Unit + std::string const &CompName, // name of the humidifier unit + [[maybe_unused]] bool const FirstHVACIteration, // TRUE if 1st HVAC simulation of system timestep + int &CompIndex // Pointer to Humidifier Unit ) { diff --git a/src/EnergyPlus/ICEngineElectricGenerator.cc b/src/EnergyPlus/ICEngineElectricGenerator.cc index 50cddd3a238..efdae6ef6fd 100644 --- a/src/EnergyPlus/ICEngineElectricGenerator.cc +++ b/src/EnergyPlus/ICEngineElectricGenerator.cc @@ -409,17 +409,19 @@ namespace ICEngineElectricGenerator { } } - void ICEngineGeneratorSpecs::getDesignCapacities(EnergyPlusData &EP_UNUSED(state), const EnergyPlus::PlantLocation &, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) + void ICEngineGeneratorSpecs::getDesignCapacities( + [[maybe_unused]] EnergyPlusData &state, const EnergyPlus::PlantLocation &, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) { MaxLoad = 0.0; MinLoad = 0.0; OptLoad = 0.0; } - void ICEngineGeneratorSpecs::simulate(EnergyPlusData &state, const EnergyPlus::PlantLocation &EP_UNUSED(calledFromLocation), + void ICEngineGeneratorSpecs::simulate(EnergyPlusData &state, + [[maybe_unused]] const EnergyPlus::PlantLocation &calledFromLocation, bool FirstHVACIteration, - Real64 &EP_UNUSED(CurLoad), - bool EP_UNUSED(RunFlag)) + [[maybe_unused]] Real64 &CurLoad, + [[maybe_unused]] bool RunFlag) { // empty function to emulate current behavior as of conversion to using the PlantComponent calling structure. // calls from the plant side only update the plant nodes. diff --git a/src/EnergyPlus/ICEngineElectricGenerator.hh b/src/EnergyPlus/ICEngineElectricGenerator.hh index f80ce2e8ef3..abd667fee9c 100644 --- a/src/EnergyPlus/ICEngineElectricGenerator.hh +++ b/src/EnergyPlus/ICEngineElectricGenerator.hh @@ -152,7 +152,7 @@ namespace ICEngineElectricGenerator { { } - void simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; + void simulate([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; void InitICEngineGenerators(EnergyPlusData &state, bool RunFlag, bool FirstHVACIteration); @@ -164,7 +164,7 @@ namespace ICEngineElectricGenerator { void setupOutputVars(EnergyPlusData &state); - void getDesignCapacities(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation), Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) override; + void getDesignCapacities(EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) override; static PlantComponent *factory(EnergyPlusData &state, std::string const &objectName); }; diff --git a/src/EnergyPlus/IceThermalStorage.cc b/src/EnergyPlus/IceThermalStorage.cc index a5823bd0caf..15cdecb9f33 100644 --- a/src/EnergyPlus/IceThermalStorage.cc +++ b/src/EnergyPlus/IceThermalStorage.cc @@ -179,9 +179,10 @@ namespace IceThermalStorage { return nullptr; // LCOV_EXCL_LINE } - void SimpleIceStorageData::simulate(EnergyPlusData &state, const PlantLocation &calledFromLocation, - bool EP_UNUSED(FirstHVACIteration), - Real64 &EP_UNUSED(CurLoad), + void SimpleIceStorageData::simulate(EnergyPlusData &state, + const PlantLocation &calledFromLocation, + [[maybe_unused]] bool FirstHVACIteration, + [[maybe_unused]] Real64 &CurLoad, bool RunFlag) { std::string const RoutineName("SimpleIceStorageData::simulate"); @@ -287,10 +288,11 @@ namespace IceThermalStorage { this->RecordOutput(MyLoad2, RunFlag); } - void DetailedIceStorageData::simulate(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation), - bool EP_UNUSED(FirstHVACIteration), - Real64 &EP_UNUSED(CurLoad), - bool EP_UNUSED(RunFlag)) + void DetailedIceStorageData::simulate(EnergyPlusData &state, + [[maybe_unused]] const PlantLocation &calledFromLocation, + [[maybe_unused]] bool FirstHVACIteration, + [[maybe_unused]] Real64 &CurLoad, + [[maybe_unused]] bool RunFlag) { if (state.dataGlobal->BeginEnvrnFlag && this->MyEnvrnFlag) { diff --git a/src/EnergyPlus/IceThermalStorage.hh b/src/EnergyPlus/IceThermalStorage.hh index c9346a4f71e..d2af21f0487 100644 --- a/src/EnergyPlus/IceThermalStorage.hh +++ b/src/EnergyPlus/IceThermalStorage.hh @@ -254,7 +254,7 @@ namespace IceThermalStorage { static PlantComponent *factory(EnergyPlusData &state, std::string const &objectName); - void simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; + void simulate([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; void InitDetailedIceStorage(EnergyPlusData &state); diff --git a/src/EnergyPlus/IntegratedHeatPump.cc b/src/EnergyPlus/IntegratedHeatPump.cc index 19e40d8b85b..558b65d2ae5 100644 --- a/src/EnergyPlus/IntegratedHeatPump.cc +++ b/src/EnergyPlus/IntegratedHeatPump.cc @@ -90,21 +90,22 @@ namespace IntegratedHeatPump { IntegratedHeatPumps.deallocate(); } - void SimIHP(EnergyPlusData &state, std::string const &CompName, // Coil Name - int &CompIndex, // Index for Component name - int const CyclingScheme, // Continuous fan OR cycling compressor - Real64 &MaxONOFFCyclesperHour, // Maximum cycling rate of heat pump [cycles/hr] - Real64 &HPTimeConstant, // Heat pump time constant [s] - Real64 &FanDelayTime, // Fan delay time, time delay for the HP's fan to - int const CompOp, // compressor on/off. 0 = off; 1= on - Real64 const PartLoadFrac, // part load fraction - int const SpeedNum, // compressor speed number - Real64 const SpeedRatio, // compressor speed ratio - Real64 const SensLoad, // Sensible demand load [W] - Real64 const LatentLoad, // Latent demand load [W] - bool const IsCallbyWH, // whether the call from the water heating loop or air loop, true = from water heating loop - bool const EP_UNUSED(FirstHVACIteration), // TRUE if First iteration of simulation - Optional OnOffAirFlowRat // ratio of comp on to comp off air flow rate + void SimIHP(EnergyPlusData &state, + std::string const &CompName, // Coil Name + int &CompIndex, // Index for Component name + int const CyclingScheme, // Continuous fan OR cycling compressor + Real64 &MaxONOFFCyclesperHour, // Maximum cycling rate of heat pump [cycles/hr] + Real64 &HPTimeConstant, // Heat pump time constant [s] + Real64 &FanDelayTime, // Fan delay time, time delay for the HP's fan to + int const CompOp, // compressor on/off. 0 = off; 1= on + Real64 const PartLoadFrac, // part load fraction + int const SpeedNum, // compressor speed number + Real64 const SpeedRatio, // compressor speed ratio + Real64 const SensLoad, // Sensible demand load [W] + Real64 const LatentLoad, // Latent demand load [W] + bool const IsCallbyWH, // whether the call from the water heating loop or air loop, true = from water heating loop + [[maybe_unused]] bool const FirstHVACIteration, // TRUE if First iteration of simulation + Optional OnOffAirFlowRat // ratio of comp on to comp off air flow rate ) { @@ -2568,10 +2569,10 @@ namespace IntegratedHeatPump { } int GetIHPDWHCoilPLFFPLR(EnergyPlusData &state, - std::string const &CoilType, // must match coil types in this module - std::string const &CoilName, // must match coil names for the coil type - IHPOperationMode const EP_UNUSED(Mode), // mode coil type - bool &ErrorsFound // set to true if problem + std::string const &CoilType, // must match coil types in this module + std::string const &CoilName, // must match coil names for the coil type + [[maybe_unused]] IHPOperationMode const Mode, // mode coil type + bool &ErrorsFound // set to true if problem ) { // FUNCTION INFORMATION: @@ -2619,10 +2620,10 @@ namespace IntegratedHeatPump { } Real64 GetDWHCoilCapacityIHP(EnergyPlusData &state, - std::string const &CoilType, // must match coil types in this module - std::string const &CoilName, // must match coil names for the coil type - IHPOperationMode const EP_UNUSED(Mode), // mode coil type - bool &ErrorsFound // set to true if problem + std::string const &CoilType, // must match coil types in this module + std::string const &CoilName, // must match coil names for the coil type + [[maybe_unused]] IHPOperationMode const Mode, // mode coil type + bool &ErrorsFound // set to true if problem ) { @@ -2881,11 +2882,12 @@ namespace IntegratedHeatPump { return (AirVolFlowRate); } - Real64 GetWaterVolFlowRateIHP(EnergyPlusData &state, + Real64 GetWaterVolFlowRateIHP( + EnergyPlusData &state, int const DXCoilNum, int const SpeedNum, Real64 const SpeedRatio, - bool const EP_UNUSED(IsCallbyWH) // whether the call from the water heating loop or air loop, true = from water heating loop + [[maybe_unused]] bool const IsCallbyWH // whether the call from the water heating loop or air loop, true = from water heating loop ) { using General::TrimSigDigits; diff --git a/src/EnergyPlus/LowTempRadiantSystem.cc b/src/EnergyPlus/LowTempRadiantSystem.cc index fe20b741adf..9abbaf911c8 100644 --- a/src/EnergyPlus/LowTempRadiantSystem.cc +++ b/src/EnergyPlus/LowTempRadiantSystem.cc @@ -5183,7 +5183,7 @@ namespace LowTempRadiantSystem { } } - void ElectricRadiantSystemData::updateLowTemperatureRadiantSystem(EnergyPlusData &EP_UNUSED(state)) + void ElectricRadiantSystemData::updateLowTemperatureRadiantSystem([[maybe_unused]] EnergyPlusData &state) { // Dummy routine: no updates are needed for electric radiant systems } @@ -5599,7 +5599,7 @@ namespace LowTempRadiantSystem { return sumHATsurf; } - void VariableFlowRadiantSystemData::reportLowTemperatureRadiantSystem(EnergyPlusData &EP_UNUSED(state)) + void VariableFlowRadiantSystemData::reportLowTemperatureRadiantSystem([[maybe_unused]] EnergyPlusData &state) { // Using/Aliasing @@ -5719,7 +5719,7 @@ namespace LowTempRadiantSystem { } } - void ElectricRadiantSystemData::reportLowTemperatureRadiantSystem(EnergyPlusData &EP_UNUSED(state)) + void ElectricRadiantSystemData::reportLowTemperatureRadiantSystem([[maybe_unused]] EnergyPlusData &state) { // Using/Aliasing diff --git a/src/EnergyPlus/MicroCHPElectricGenerator.cc b/src/EnergyPlus/MicroCHPElectricGenerator.cc index 9863a927b3e..da203204cd5 100644 --- a/src/EnergyPlus/MicroCHPElectricGenerator.cc +++ b/src/EnergyPlus/MicroCHPElectricGenerator.cc @@ -537,10 +537,11 @@ namespace MicroCHPElectricGenerator { } } - void MicroCHPDataStruct::simulate(EnergyPlusData &state, const EnergyPlus::PlantLocation &EP_UNUSED(calledFromLocation), + void MicroCHPDataStruct::simulate(EnergyPlusData &state, + [[maybe_unused]] const EnergyPlus::PlantLocation &calledFromLocation, bool FirstHVACIteration, - Real64 &EP_UNUSED(CurLoad), - bool EP_UNUSED(RunFlag)) + [[maybe_unused]] Real64 &CurLoad, + [[maybe_unused]] bool RunFlag) { // empty function to emulate current behavior as of conversion to using the PlantComponent calling structure. // calls from the plant side only update the nodes. @@ -1319,7 +1320,8 @@ namespace MicroCHPElectricGenerator { DataLoopNode::Node(this->PlantOutletNodeID).Enthalpy = this->A42Model.TcwOut * Cp; } - void MicroCHPDataStruct::getDesignCapacities(EnergyPlusData &EP_UNUSED(state), const EnergyPlus::PlantLocation &, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) + void MicroCHPDataStruct::getDesignCapacities( + [[maybe_unused]] EnergyPlusData &state, const EnergyPlus::PlantLocation &, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) { MaxLoad = DataGenerators::GeneratorDynamics(this->DynamicsControlID).QdotHXMax; MinLoad = DataGenerators::GeneratorDynamics(this->DynamicsControlID).QdotHXMin; diff --git a/src/EnergyPlus/MicroCHPElectricGenerator.hh b/src/EnergyPlus/MicroCHPElectricGenerator.hh index 70b70ff730c..80dc2a624de 100644 --- a/src/EnergyPlus/MicroCHPElectricGenerator.hh +++ b/src/EnergyPlus/MicroCHPElectricGenerator.hh @@ -200,11 +200,11 @@ namespace MicroCHPElectricGenerator { { } - void simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; + void simulate([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; - void getDesignCapacities(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation), Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) override; + void getDesignCapacities(EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) override; - void onInitLoopEquip(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation)) override; + void onInitLoopEquip(EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation) override; void setupOutputVars(EnergyPlusData &state); diff --git a/src/EnergyPlus/MicroturbineElectricGenerator.cc b/src/EnergyPlus/MicroturbineElectricGenerator.cc index ba2760db1c6..636ba892c01 100644 --- a/src/EnergyPlus/MicroturbineElectricGenerator.cc +++ b/src/EnergyPlus/MicroturbineElectricGenerator.cc @@ -871,17 +871,22 @@ namespace MicroturbineElectricGenerator { } } - void MTGeneratorSpecs::simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &EP_UNUSED(calledFromLocation), - bool EP_UNUSED(FirstHVACIteration), - Real64 &EP_UNUSED(CurLoad), - bool EP_UNUSED(RunFlag)) + void MTGeneratorSpecs::simulate([[maybe_unused]] EnergyPlusData &state, + [[maybe_unused]] const PlantLocation &calledFromLocation, + [[maybe_unused]] bool FirstHVACIteration, + [[maybe_unused]] Real64 &CurLoad, + [[maybe_unused]] bool RunFlag) { // empty function to emulate current behavior as of conversion to using the PlantComponent calling structure. // calls from the plant side... do nothing. // calls from the ElectricPowerServiceManger call the init, calc, and update worker functions } - void MTGeneratorSpecs::getDesignCapacities(EnergyPlusData &EP_UNUSED(state), const PlantLocation &EP_UNUSED(calledFromLocation), Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) + void MTGeneratorSpecs::getDesignCapacities([[maybe_unused]] EnergyPlusData &state, + [[maybe_unused]] const PlantLocation &calledFromLocation, + Real64 &MaxLoad, + Real64 &MinLoad, + Real64 &OptLoad) { MaxLoad = 0.0; MinLoad = 0.0; diff --git a/src/EnergyPlus/MicroturbineElectricGenerator.hh b/src/EnergyPlus/MicroturbineElectricGenerator.hh index 283e8b494fc..979ec08e224 100644 --- a/src/EnergyPlus/MicroturbineElectricGenerator.hh +++ b/src/EnergyPlus/MicroturbineElectricGenerator.hh @@ -198,13 +198,13 @@ namespace MicroturbineElectricGenerator { { } - void simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; + void simulate([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; void getDesignCapacities(EnergyPlusData &state, - const PlantLocation &EP_UNUSED(calledFromLocation), - Real64 &EP_UNUSED(MaxLoad), - Real64 &EP_UNUSED(MinLoad), - Real64 &EP_UNUSED(OptLoad)) override; + [[maybe_unused]] const PlantLocation &calledFromLocation, + [[maybe_unused]] Real64 &MaxLoad, + [[maybe_unused]] Real64 &MinLoad, + [[maybe_unused]] Real64 &OptLoad) override; void InitMTGenerators(EnergyPlusData &state, bool RunFlag, diff --git a/src/EnergyPlus/MixedAir.cc b/src/EnergyPlus/MixedAir.cc index 94e52e69975..1abb11b98c2 100644 --- a/src/EnergyPlus/MixedAir.cc +++ b/src/EnergyPlus/MixedAir.cc @@ -5181,7 +5181,7 @@ CurrentModuleObjects(CMO_SysAvailMgrList), AvailManagerListName); } } - void ReportOAMixer(int const EP_UNUSED(OAMixerNum)) // unused1208 + void ReportOAMixer([[maybe_unused]] int const OAMixerNum) // unused1208 { // SUBROUTINE ARGUMENT DEFINITIONS diff --git a/src/EnergyPlus/MixerComponent.cc b/src/EnergyPlus/MixerComponent.cc index 3c6b2e51959..b129035101e 100644 --- a/src/EnergyPlus/MixerComponent.cc +++ b/src/EnergyPlus/MixerComponent.cc @@ -605,7 +605,7 @@ namespace MixerComponent { // Beginning of Reporting subroutines for the Mixer Module // ***************************************************************************** - void ReportMixer(int const EP_UNUSED(MixerNum)) + void ReportMixer([[maybe_unused]] int const MixerNum) { // SUBROUTINE INFORMATION: diff --git a/src/EnergyPlus/OutdoorAirUnit.cc b/src/EnergyPlus/OutdoorAirUnit.cc index 300558fb4d5..38955182dc9 100644 --- a/src/EnergyPlus/OutdoorAirUnit.cc +++ b/src/EnergyPlus/OutdoorAirUnit.cc @@ -2112,7 +2112,7 @@ CurrentModuleObjects(CO_OAEqList), ComponentListName); std::string const &EquipType, // the component type std::string const &EquipName, // the component Name int const EquipNum, - int const EP_UNUSED(CompTypeNum), // Component Type -- Integerized for this module + [[maybe_unused]] int const CompTypeNum, // Component Type -- Integerized for this module bool const FirstHVACIteration, int &CompIndex, bool const Sim // if TRUE, simulate component diff --git a/src/EnergyPlus/OutputProcessor.cc b/src/EnergyPlus/OutputProcessor.cc index a9b6f0292ec..c92829ced9b 100644 --- a/src/EnergyPlus/OutputProcessor.cc +++ b/src/EnergyPlus/OutputProcessor.cc @@ -710,7 +710,7 @@ namespace OutputProcessor { } } - static std::string frequencyNotice(StoreType EP_UNUSED(storeType), ReportingFrequency reportingInterval) + static std::string frequencyNotice([[maybe_unused]] StoreType storeType, ReportingFrequency reportingInterval) { switch (reportingInterval) { case ReportingFrequency::EachCall: @@ -3937,7 +3937,10 @@ namespace OutputProcessor { // End of routines for Energy Meters implementation in EnergyPlus. // ***************************************************************************** - void AddEndUseSubcategory(EnergyPlusData &state, std::string const &EP_UNUSED(ResourceName), std::string const &EndUseName, std::string const &EndUseSubName) + void AddEndUseSubcategory(EnergyPlusData &state, + [[maybe_unused]] std::string const &ResourceName, + std::string const &EndUseName, + std::string const &EndUseSubName) { // SUBROUTINE INFORMATION: @@ -4164,12 +4167,12 @@ namespace OutputProcessor { void WriteReportVariableDictionaryItem(EnergyPlusData &state, ReportingFrequency const reportingInterval, // The reporting interval (e.g., hourly, daily) StoreType const storeType, - int const reportID, // The reporting ID for the data - int const EP_UNUSED(indexGroupKey), // The reporting group (e.g., Zone, Plant Loop, etc.) - std::string const &indexGroup, // The reporting group (e.g., Zone, Plant Loop, etc.) - std::string const &reportIDChr, // The reporting ID for the data - std::string const &keyedValue, // The key name for the data - std::string const &variableName, // The variable's actual name + int const reportID, // The reporting ID for the data + [[maybe_unused]] int const indexGroupKey, // The reporting group (e.g., Zone, Plant Loop, etc.) + std::string const &indexGroup, // The reporting group (e.g., Zone, Plant Loop, etc.) + std::string const &reportIDChr, // The reporting ID for the data + std::string const &keyedValue, // The key name for the data + std::string const &variableName, // The variable's actual name TimeStepType const timeStepType, OutputProcessor::Unit const &unitsForVar, // The variables units Optional_string_const customUnitName, @@ -4275,14 +4278,14 @@ namespace OutputProcessor { void WriteMeterDictionaryItem(EnergyPlusData &state, ReportingFrequency const reportingInterval, // The reporting interval (e.g., hourly, daily) StoreType const storeType, - int const reportID, // The reporting ID in for the variable - int const EP_UNUSED(indexGroupKey), // The reporting group for the variable - std::string const &indexGroup, // The reporting group for the variable - std::string const &reportIDChr, // The reporting ID in for the variable - std::string const &meterName, // The variable's meter name - OutputProcessor::Unit const &unit, // The variables units - bool const cumulativeMeterFlag, // A flag indicating cumulative data - bool const meterFileOnlyFlag // A flag indicating whether the data is to be written to standard output + int const reportID, // The reporting ID in for the variable + [[maybe_unused]] int const indexGroupKey, // The reporting group for the variable + std::string const &indexGroup, // The reporting group for the variable + std::string const &reportIDChr, // The reporting ID in for the variable + std::string const &meterName, // The variable's meter name + OutputProcessor::Unit const &unit, // The variables units + bool const cumulativeMeterFlag, // A flag indicating cumulative data + bool const meterFileOnlyFlag // A flag indicating whether the data is to be written to standard output ) { @@ -7820,8 +7823,8 @@ Real64 GetInternalVariableValueExternalInterface(EnergyPlusData &state, int cons return resultVal; } -int GetNumMeteredVariables(std::string const &EP_UNUSED(ComponentType), // Given Component Type - std::string const &ComponentName // Given Component Name (user defined) +int GetNumMeteredVariables([[maybe_unused]] std::string const &ComponentType, // Given Component Type + std::string const &ComponentName // Given Component Name (user defined) ) { diff --git a/src/EnergyPlus/OutsideEnergySources.cc b/src/EnergyPlus/OutsideEnergySources.cc index 1ea611758db..8710c566608 100644 --- a/src/EnergyPlus/OutsideEnergySources.cc +++ b/src/EnergyPlus/OutsideEnergySources.cc @@ -132,8 +132,11 @@ namespace OutsideEnergySources { return nullptr; // LCOV_EXCL_LINE } - void OutsideEnergySourceSpecs::simulate( - EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation), bool EP_UNUSED(FirstHVACIteration), Real64 &CurLoad, bool RunFlag) + void OutsideEnergySourceSpecs::simulate(EnergyPlusData &state, + [[maybe_unused]] const PlantLocation &calledFromLocation, + [[maybe_unused]] bool FirstHVACIteration, + Real64 &CurLoad, + bool RunFlag) { this->initialize(state, CurLoad); this->calculate(state, RunFlag, CurLoad); @@ -145,8 +148,8 @@ namespace OutsideEnergySources { this->size(state); } - void OutsideEnergySourceSpecs::getDesignCapacities(EnergyPlusData &EP_UNUSED(state), - const PlantLocation &EP_UNUSED(calledFromLocation), + void OutsideEnergySourceSpecs::getDesignCapacities([[maybe_unused]] EnergyPlusData &state, + [[maybe_unused]] const PlantLocation &calledFromLocation, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) diff --git a/src/EnergyPlus/OutsideEnergySources.hh b/src/EnergyPlus/OutsideEnergySources.hh index be188a8ff22..299cfd37855 100644 --- a/src/EnergyPlus/OutsideEnergySources.hh +++ b/src/EnergyPlus/OutsideEnergySources.hh @@ -97,10 +97,10 @@ namespace OutsideEnergySources { static PlantComponent *factory(EnergyPlusData &state, int objectType, std::string objectName); - void simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, + void simulate([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; - void onInitLoopEquip(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation) override; + void onInitLoopEquip([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation) override; void getDesignCapacities(EnergyPlusData &state, const PlantLocation &calledFromLocation, diff --git a/src/EnergyPlus/PackagedTerminalHeatPump.cc b/src/EnergyPlus/PackagedTerminalHeatPump.cc index f7747b81052..ef6656abd0a 100644 --- a/src/EnergyPlus/PackagedTerminalHeatPump.cc +++ b/src/EnergyPlus/PackagedTerminalHeatPump.cc @@ -8072,7 +8072,7 @@ namespace PackagedTerminalHeatPump { Real64 const QLatReq, // Zone latent load [] Real64 &OnOffAirFlowRatio, // ratio of compressor ON airflow to AVERAGE airflow over timestep Real64 &SupHeaterLoad, // supplemental heater load (W) - bool const EP_UNUSED(HXUnitOn) // flag to enable heat exchanger + [[maybe_unused]] bool const HXUnitOn // flag to enable heat exchanger ) { // SUBROUTINE INFORMATION: @@ -8535,12 +8535,12 @@ namespace PackagedTerminalHeatPump { } void SetVSHPAirFlow(EnergyPlusData &state, - int const PTUnitNum, // Unit index - int const EP_UNUSED(ZoneNum), // Zone index - Real64 const PartLoadRatio, // unit part load ratio - Real64 &OnOffAirFlowRatio, // ratio of compressor ON airflow to average airflow over timestep - Optional_int_const SpeedNum, // Speed number - Optional SpeedRatio // Speed ratio + int const PTUnitNum, // Unit index + [[maybe_unused]] int const ZoneNum, // Zone index + Real64 const PartLoadRatio, // unit part load ratio + Real64 &OnOffAirFlowRatio, // ratio of compressor ON airflow to average airflow over timestep + Optional_int_const SpeedNum, // Speed number + Optional SpeedRatio // Speed ratio ) { @@ -8709,15 +8709,15 @@ namespace PackagedTerminalHeatPump { } void SetOnOffMassFlowRateVSCoil(EnergyPlusData &state, - int const PTUnitNum, // index to furnace - int const ZoneNum, // index to zone - bool const FirstHVACIteration, // Flag for 1st HVAC iteration - int const EP_UNUSED(AirLoopNum), // index to air loop !unused1208 - Real64 &OnOffAirFlowRatio, // ratio of coil on to coil off air flow rate - int const EP_UNUSED(OpMode), // fan operating mode - Real64 const EP_UNUSED(QZnReq), // sensible load to be met (W) !unused1208 - Real64 const EP_UNUSED(MoistureLoad), // moisture load to be met (W) - Real64 &PartLoadRatio // coil part-load ratio + int const PTUnitNum, // index to furnace + int const ZoneNum, // index to zone + bool const FirstHVACIteration, // Flag for 1st HVAC iteration + [[maybe_unused]] int const AirLoopNum, // index to air loop !unused1208 + Real64 &OnOffAirFlowRatio, // ratio of coil on to coil off air flow rate + [[maybe_unused]] int const OpMode, // fan operating mode + [[maybe_unused]] Real64 const QZnReq, // sensible load to be met (W) !unused1208 + [[maybe_unused]] Real64 const MoistureLoad, // moisture load to be met (W) + Real64 &PartLoadRatio // coil part-load ratio ) { diff --git a/src/EnergyPlus/PackagedThermalStorageCoil.cc b/src/EnergyPlus/PackagedThermalStorageCoil.cc index 933c3e96ec8..701531eaa49 100644 --- a/src/EnergyPlus/PackagedThermalStorageCoil.cc +++ b/src/EnergyPlus/PackagedThermalStorageCoil.cc @@ -2462,7 +2462,7 @@ namespace PackagedThermalStorageCoil { } } - void CalcTESCoilCoolingOnlyMode(EnergyPlusData &state, int const TESCoilNum, int const EP_UNUSED(FanOpMode), Real64 const PartLoadRatio) + void CalcTESCoilCoolingOnlyMode(EnergyPlusData &state, int const TESCoilNum, [[maybe_unused]] int const FanOpMode, Real64 const PartLoadRatio) { // SUBROUTINE INFORMATION: @@ -2768,7 +2768,8 @@ namespace PackagedThermalStorageCoil { } } - void CalcTESCoilCoolingAndChargeMode(EnergyPlusData &state, int const TESCoilNum, int const EP_UNUSED(FanOpMode), Real64 const PartLoadRatio) + void + CalcTESCoilCoolingAndChargeMode(EnergyPlusData &state, int const TESCoilNum, [[maybe_unused]] int const FanOpMode, Real64 const PartLoadRatio) { // SUBROUTINE INFORMATION: @@ -3199,7 +3200,8 @@ namespace PackagedThermalStorageCoil { } } - void CalcTESCoilCoolingAndDischargeMode(EnergyPlusData &state, int const TESCoilNum, int const EP_UNUSED(FanOpMode), Real64 const PartLoadRatio) + void + CalcTESCoilCoolingAndDischargeMode(EnergyPlusData &state, int const TESCoilNum, [[maybe_unused]] int const FanOpMode, Real64 const PartLoadRatio) { // SUBROUTINE INFORMATION: diff --git a/src/EnergyPlus/PhotovoltaicThermalCollectors.cc b/src/EnergyPlus/PhotovoltaicThermalCollectors.cc index 19dad86c8f1..cf9103aa8f7 100644 --- a/src/EnergyPlus/PhotovoltaicThermalCollectors.cc +++ b/src/EnergyPlus/PhotovoltaicThermalCollectors.cc @@ -139,17 +139,17 @@ namespace PhotovoltaicThermalCollectors { return nullptr; } - void PVTCollectorStruct::onInitLoopEquip(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation)) + void PVTCollectorStruct::onInitLoopEquip(EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation) { this->initialize(state, true); this->size(state); } void PVTCollectorStruct::simulate(EnergyPlusData &state, - const PlantLocation &EP_UNUSED(calledFromLocation), + [[maybe_unused]] const PlantLocation &calledFromLocation, bool const FirstHVACIteration, - Real64 &EP_UNUSED(CurLoad), - bool const EP_UNUSED(RunFlag)) + [[maybe_unused]] Real64 &CurLoad, + [[maybe_unused]] bool const RunFlag) { this->initialize(state, FirstHVACIteration); diff --git a/src/EnergyPlus/PhotovoltaicThermalCollectors.hh b/src/EnergyPlus/PhotovoltaicThermalCollectors.hh index 9b805d5ee2b..9cdc29895e3 100644 --- a/src/EnergyPlus/PhotovoltaicThermalCollectors.hh +++ b/src/EnergyPlus/PhotovoltaicThermalCollectors.hh @@ -163,9 +163,9 @@ namespace PhotovoltaicThermalCollectors { static PlantComponent *factory(EnergyPlusData &state, std::string const &objectName); - void onInitLoopEquip(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation) override; + void onInitLoopEquip([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation) override; - void simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; + void simulate([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; void setupReportVars(EnergyPlusData &state); diff --git a/src/EnergyPlus/Photovoltaics.cc b/src/EnergyPlus/Photovoltaics.cc index f11cb86501a..528ad428096 100644 --- a/src/EnergyPlus/Photovoltaics.cc +++ b/src/EnergyPlus/Photovoltaics.cc @@ -137,11 +137,11 @@ namespace Photovoltaics { } void SimPVGenerator(EnergyPlusData &state, - GeneratorType const EP_UNUSED(GeneratorType), // type of Generator !unused1208 - std::string const &GeneratorName, // user specified name of Generator + [[maybe_unused]] GeneratorType const GeneratorType, // type of Generator !unused1208 + std::string const &GeneratorName, // user specified name of Generator int &GeneratorIndex, - bool const RunFlag, // is PV ON or OFF as determined by schedules in ElecLoadCenter - Real64 const EP_UNUSED(PVLoad) // electrical load on the PV (not really used... PV models assume "full on" !unused1208 + bool const RunFlag, // is PV ON or OFF as determined by schedules in ElecLoadCenter + [[maybe_unused]] Real64 const PVLoad // electrical load on the PV (not really used... PV models assume "full on" !unused1208 ) { @@ -217,7 +217,7 @@ namespace Photovoltaics { ReportPV(state, PVnum); } - void GetPVGeneratorResults(GeneratorType const EP_UNUSED(GeneratorType), // type of Generator !unused1208 + void GetPVGeneratorResults([[maybe_unused]] GeneratorType const GeneratorType, // type of Generator !unused1208 int const GeneratorIndex, Real64 &GeneratorPower, // electrical power Real64 &GeneratorEnergy, // electrical energy diff --git a/src/EnergyPlus/PipeHeatTransfer.cc b/src/EnergyPlus/PipeHeatTransfer.cc index 22ad365f13f..ed2f954fa78 100644 --- a/src/EnergyPlus/PipeHeatTransfer.cc +++ b/src/EnergyPlus/PipeHeatTransfer.cc @@ -196,10 +196,11 @@ namespace PipeHeatTransfer { MyEnvrnFlag = true; } - void PipeHTData::simulate(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation), + void PipeHTData::simulate(EnergyPlusData &state, + [[maybe_unused]] const PlantLocation &calledFromLocation, bool const FirstHVACIteration, - Real64 &EP_UNUSED(CurLoad), - bool const EP_UNUSED(RunFlag)) + [[maybe_unused]] Real64 &CurLoad, + [[maybe_unused]] bool const RunFlag) { this->InitPipesHeatTransfer(state, FirstHVACIteration); // make the calculations diff --git a/src/EnergyPlus/PipeHeatTransfer.hh b/src/EnergyPlus/PipeHeatTransfer.hh index f026dfcd8fc..8102b4d2574 100644 --- a/src/EnergyPlus/PipeHeatTransfer.hh +++ b/src/EnergyPlus/PipeHeatTransfer.hh @@ -243,7 +243,7 @@ namespace PipeHeatTransfer { static PlantComponent *factory(EnergyPlusData &state, int objectType, std::string objectName); - void simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, bool const FirstHVACIteration, Real64 &CurLoad, bool const RunFlag) override; + void simulate([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, bool const FirstHVACIteration, Real64 &CurLoad, bool const RunFlag) override; void PushInnerTimeStepArrays(); diff --git a/src/EnergyPlus/Pipes.cc b/src/EnergyPlus/Pipes.cc index 27da30c0826..03344a1795a 100644 --- a/src/EnergyPlus/Pipes.cc +++ b/src/EnergyPlus/Pipes.cc @@ -138,10 +138,11 @@ namespace Pipes { return nullptr; // LCOV_EXCL_LINE } - void LocalPipeData::simulate(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation), - bool const EP_UNUSED(FirstHVACIteration), - Real64 &EP_UNUSED(CurLoad), - bool const EP_UNUSED(RunFlag)) + void LocalPipeData::simulate(EnergyPlusData &state, + [[maybe_unused]] const PlantLocation &calledFromLocation, + [[maybe_unused]] bool const FirstHVACIteration, + [[maybe_unused]] Real64 &CurLoad, + [[maybe_unused]] bool const RunFlag) { if (this->OneTimeInit) { int FoundOnLoop = 0; diff --git a/src/EnergyPlus/Pipes.hh b/src/EnergyPlus/Pipes.hh index e2bdf0b8663..f345f8f589f 100644 --- a/src/EnergyPlus/Pipes.hh +++ b/src/EnergyPlus/Pipes.hh @@ -90,7 +90,7 @@ namespace Pipes { } static PlantComponent *factory(EnergyPlusData &state, int objectType, std::string objectName); - void simulate(EnergyPlusData &EP_UNUSED(states), const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; + void simulate([[maybe_unused]] EnergyPlusData &states, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; }; // Object Data diff --git a/src/EnergyPlus/Plant/PlantManager.cc b/src/EnergyPlus/Plant/PlantManager.cc index 6194f5d85df..6a2460a0bc6 100644 --- a/src/EnergyPlus/Plant/PlantManager.cc +++ b/src/EnergyPlus/Plant/PlantManager.cc @@ -168,14 +168,15 @@ namespace EnergyPlus { DemandSideInletNode.deallocate(); } - void ManagePlantLoops(EnergyPlusData &state, bool const FirstHVACIteration, - bool &SimAirLoops, // True when the air loops need to be (re)simulated - bool &SimZoneEquipment, // True when zone equipment components need to be (re)simulated - bool &EP_UNUSED( - SimNonZoneEquipment), // True when non-zone equipment components need to be (re)simulated - bool &SimPlantLoops, // True when some part of Plant needs to be (re)simulated - bool &SimElecCircuits // True when electic circuits need to be (re)simulated - ) { + void ManagePlantLoops(EnergyPlusData &state, + bool const FirstHVACIteration, + bool &SimAirLoops, // True when the air loops need to be (re)simulated + bool &SimZoneEquipment, // True when zone equipment components need to be (re)simulated + [[maybe_unused]] bool &SimNonZoneEquipment, // True when non-zone equipment components need to be (re)simulated + bool &SimPlantLoops, // True when some part of Plant needs to be (re)simulated + bool &SimElecCircuits // True when electic circuits need to be (re)simulated + ) + { // SUBROUTINE INFORMATION: // AUTHOR Sankaranarayanan K P diff --git a/src/EnergyPlus/PlantCentralGSHP.cc b/src/EnergyPlus/PlantCentralGSHP.cc index 2c3ffde90fb..d30b70c7814 100644 --- a/src/EnergyPlus/PlantCentralGSHP.cc +++ b/src/EnergyPlus/PlantCentralGSHP.cc @@ -165,7 +165,8 @@ namespace PlantCentralGSHP { this->SizeWrapper(state); } - void WrapperSpecs::getDesignCapacities(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) + void WrapperSpecs::getDesignCapacities( + [[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) { MinLoad = 0.0; MaxLoad = 0.0; @@ -195,7 +196,7 @@ namespace PlantCentralGSHP { } void WrapperSpecs::simulate( - EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool EP_UNUSED(RunFlag)) + EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, [[maybe_unused]] bool RunFlag) { if (calledFromLocation.loopNum != this->GLHELoopNum) { diff --git a/src/EnergyPlus/PlantCentralGSHP.hh b/src/EnergyPlus/PlantCentralGSHP.hh index 02d493fd9c1..b8e2e6f6990 100644 --- a/src/EnergyPlus/PlantCentralGSHP.hh +++ b/src/EnergyPlus/PlantCentralGSHP.hh @@ -409,7 +409,7 @@ namespace PlantCentralGSHP { int LoopNum // Loop Number Index ); - void simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; + void simulate([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; void SizeWrapper(EnergyPlusData &state); @@ -423,7 +423,7 @@ namespace PlantCentralGSHP { void UpdateChillerRecords(); - void onInitLoopEquip(EnergyPlusData &EP_UNUSED(state), const PlantLocation &EP_UNUSED(calledFromLocation)) override; + void onInitLoopEquip([[maybe_unused]] EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation) override; }; diff --git a/src/EnergyPlus/PlantChillers.cc b/src/EnergyPlus/PlantChillers.cc index 8da21bd1bf7..75aa4a7cdd3 100644 --- a/src/EnergyPlus/PlantChillers.cc +++ b/src/EnergyPlus/PlantChillers.cc @@ -109,7 +109,8 @@ namespace PlantChillers { // Parameters for use in Chillers Real64 constexpr KJtoJ(1000.0); // convert Kjoules to joules - void BaseChillerSpecs::getDesignCapacities(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) + void BaseChillerSpecs::getDesignCapacities( + [[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) { if (calledFromLocation.loopNum == this->CWLoopNum) { MinLoad = this->NomCap * this->MinPartLoadRat; diff --git a/src/EnergyPlus/PlantChillers.hh b/src/EnergyPlus/PlantChillers.hh index 75b7b364005..b9e84f81a49 100644 --- a/src/EnergyPlus/PlantChillers.hh +++ b/src/EnergyPlus/PlantChillers.hh @@ -175,16 +175,16 @@ namespace PlantChillers { } void getDesignCapacities(EnergyPlusData &state, - const PlantLocation &EP_UNUSED(calledFromLocation), - Real64 &EP_UNUSED(MaxLoad), - Real64 &EP_UNUSED(MinLoad), - Real64 &EP_UNUSED(OptLoad)) override; + [[maybe_unused]] const PlantLocation &calledFromLocation, + [[maybe_unused]] Real64 &MaxLoad, + [[maybe_unused]] Real64 &MinLoad, + [[maybe_unused]] Real64 &OptLoad) override; - void getSizingFactor(Real64 &EP_UNUSED(SizFac)) override; + void getSizingFactor([[maybe_unused]] Real64 &SizFac) override; - void onInitLoopEquip(EnergyPlusData &EP_UNUSED(state), const PlantLocation &EP_UNUSED(calledFromLocation)) override; + void onInitLoopEquip([[maybe_unused]] EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation) override; - void getDesignTemperatures(Real64 &EP_UNUSED(TempDesCondIn), Real64 &EP_UNUSED(TempDesEvapOut)) override; + void getDesignTemperatures([[maybe_unused]] Real64 &TempDesCondIn, [[maybe_unused]] Real64 &TempDesEvapOut) override; virtual void initialize(EnergyPlusData &state, bool RunFlag, Real64 MyLoad) = 0; @@ -239,7 +239,7 @@ namespace PlantChillers { static ElectricChillerSpecs *factory(EnergyPlusData &state, std::string const &chillerName); - void simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; + void simulate([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; void initialize(EnergyPlusData &state, bool RunFlag, Real64 MyLoad) override; @@ -336,7 +336,7 @@ namespace PlantChillers { static void getInput(EnergyPlusData &state); - void simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; + void simulate([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; void setupOutputVariables(EnergyPlusData &state); @@ -430,7 +430,7 @@ namespace PlantChillers { static void getInput(EnergyPlusData &state); - void simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; + void simulate([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; void setupOutputVariables(EnergyPlusData &state); @@ -463,7 +463,7 @@ namespace PlantChillers { static void getInput(EnergyPlusData &state); - void simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; + void simulate([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; void setupOutputVariables(EnergyPlusData &state); diff --git a/src/EnergyPlus/PlantComponent.hh b/src/EnergyPlus/PlantComponent.hh index 35f91fed8f9..067a7f22cd5 100644 --- a/src/EnergyPlus/PlantComponent.hh +++ b/src/EnergyPlus/PlantComponent.hh @@ -62,23 +62,23 @@ class PlantComponent public: virtual void simulate(EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) = 0; - virtual void getDesignCapacities(EnergyPlusData &EP_UNUSED(state), - const PlantLocation &EP_UNUSED(calledFromLocation), - Real64 &EP_UNUSED(MaxLoad), - Real64 &EP_UNUSED(MinLoad), - Real64 &EP_UNUSED(OptLoad)) + virtual void getDesignCapacities([[maybe_unused]] EnergyPlusData &state, + [[maybe_unused]] const PlantLocation &calledFromLocation, + [[maybe_unused]] Real64 &MaxLoad, + [[maybe_unused]] Real64 &MinLoad, + [[maybe_unused]] Real64 &OptLoad) { } - virtual void getDesignTemperatures(Real64 &EP_UNUSED(TempDesCondIn), Real64 &EP_UNUSED(TempDesEvapOut)) + virtual void getDesignTemperatures([[maybe_unused]] Real64 &TempDesCondIn, [[maybe_unused]] Real64 &TempDesEvapOut) { } - virtual void getSizingFactor(Real64 &EP_UNUSED(SizFac)) + virtual void getSizingFactor([[maybe_unused]] Real64 &SizFac) { } - virtual void onInitLoopEquip(EnergyPlusData &EP_UNUSED(state), const PlantLocation &EP_UNUSED(calledFromLocation)) + virtual void onInitLoopEquip([[maybe_unused]] EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation) { } diff --git a/src/EnergyPlus/PlantComponentTemperatureSources.cc b/src/EnergyPlus/PlantComponentTemperatureSources.cc index ec5bd3abb96..608facecc54 100644 --- a/src/EnergyPlus/PlantComponentTemperatureSources.cc +++ b/src/EnergyPlus/PlantComponentTemperatureSources.cc @@ -400,17 +400,18 @@ namespace PlantComponentTemperatureSources { } void WaterSourceSpecs::simulate(EnergyPlusData &state, - const PlantLocation &EP_UNUSED(calledFromLocation), - bool EP_UNUSED(FirstHVACIteration), + [[maybe_unused]] const PlantLocation &calledFromLocation, + [[maybe_unused]] bool FirstHVACIteration, Real64 &CurLoad, - bool EP_UNUSED(RunFlag)) + [[maybe_unused]] bool RunFlag) { this->initialize(state, CurLoad); this->calculate(state); this->update(); } - void WaterSourceSpecs::getDesignCapacities(EnergyPlusData &EP_UNUSED(state), const EnergyPlus::PlantLocation &, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) + void WaterSourceSpecs::getDesignCapacities( + [[maybe_unused]] EnergyPlusData &state, const EnergyPlus::PlantLocation &, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) { MaxLoad = DataGlobalConstants::BigNumber(); diff --git a/src/EnergyPlus/PlantComponentTemperatureSources.hh b/src/EnergyPlus/PlantComponentTemperatureSources.hh index bc6c3350a28..b210a6ab7cb 100644 --- a/src/EnergyPlus/PlantComponentTemperatureSources.hh +++ b/src/EnergyPlus/PlantComponentTemperatureSources.hh @@ -124,7 +124,7 @@ namespace PlantComponentTemperatureSources { void simulate(EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; - void getDesignCapacities(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation), Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) override; + void getDesignCapacities(EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) override; void getSizingFactor(Real64 &_SizFac) override; diff --git a/src/EnergyPlus/PlantCondLoopOperation.cc b/src/EnergyPlus/PlantCondLoopOperation.cc index bc29a543ba5..863747ac057 100644 --- a/src/EnergyPlus/PlantCondLoopOperation.cc +++ b/src/EnergyPlus/PlantCondLoopOperation.cc @@ -3046,7 +3046,7 @@ CurrentModuleObject, PlantOpSchemeName); int const CurCompLevelOpNum, // index for Plant()%LoopSide()%Branch()%Comp()%OpScheme() int const CurSchemePtr, Real64 const LoopDemand, - Real64 &EP_UNUSED(RemLoopDemand)) + [[maybe_unused]] Real64 &RemLoopDemand) { // SUBROUTINE INFORMATION: diff --git a/src/EnergyPlus/PlantHeatExchangerFluidToFluid.cc b/src/EnergyPlus/PlantHeatExchangerFluidToFluid.cc index 56fac7daecb..f1d7e1e0e1d 100644 --- a/src/EnergyPlus/PlantHeatExchangerFluidToFluid.cc +++ b/src/EnergyPlus/PlantHeatExchangerFluidToFluid.cc @@ -153,7 +153,7 @@ namespace PlantHeatExchangerFluidToFluid { return nullptr; // LCOV_EXCL_LINE } - void HeatExchangerStruct::onInitLoopEquip(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation)) + void HeatExchangerStruct::onInitLoopEquip(EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation) { this->initialize(state); } @@ -172,8 +172,11 @@ namespace PlantHeatExchangerFluidToFluid { } } - void HeatExchangerStruct::simulate( - EnergyPlusData &state, const PlantLocation &calledFromLocation, bool const FirstHVACIteration, Real64 &CurLoad, bool const EP_UNUSED(RunFlag)) + void HeatExchangerStruct::simulate(EnergyPlusData &state, + const PlantLocation &calledFromLocation, + bool const FirstHVACIteration, + Real64 &CurLoad, + [[maybe_unused]] bool const RunFlag) { // SUBROUTINE INFORMATION: @@ -1045,7 +1048,7 @@ namespace PlantHeatExchangerFluidToFluid { } } - void HeatExchangerStruct::control(EnergyPlusData &state, int const EP_UNUSED(LoopNum), Real64 const MyLoad, bool FirstHVACIteration) + void HeatExchangerStruct::control(EnergyPlusData &state, [[maybe_unused]] int const LoopNum, Real64 const MyLoad, bool FirstHVACIteration) { // SUBROUTINE INFORMATION: diff --git a/src/EnergyPlus/PlantHeatExchangerFluidToFluid.hh b/src/EnergyPlus/PlantHeatExchangerFluidToFluid.hh index 7ad6de9ed8a..076db68d8a5 100644 --- a/src/EnergyPlus/PlantHeatExchangerFluidToFluid.hh +++ b/src/EnergyPlus/PlantHeatExchangerFluidToFluid.hh @@ -153,11 +153,11 @@ namespace PlantHeatExchangerFluidToFluid { static PlantComponent *factory(EnergyPlusData &state, std::string const &objectName); - void onInitLoopEquip(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation) override; + void onInitLoopEquip([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation) override; void getDesignCapacities(EnergyPlusData &state, const PlantLocation &calledFromLocation, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) override; - void simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; + void simulate([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; void setupOutputVars(EnergyPlusData &state); diff --git a/src/EnergyPlus/PlantLoadProfile.cc b/src/EnergyPlus/PlantLoadProfile.cc index 29359aef350..6f33cce61e2 100644 --- a/src/EnergyPlus/PlantLoadProfile.cc +++ b/src/EnergyPlus/PlantLoadProfile.cc @@ -119,15 +119,16 @@ namespace PlantLoadProfile { return nullptr; } - void PlantProfileData::onInitLoopEquip(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation)) + void PlantProfileData::onInitLoopEquip(EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation) { this->InitPlantProfile(state); } - void PlantProfileData::simulate(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation), - bool const EP_UNUSED(FirstHVACIteration), - Real64 &EP_UNUSED(CurLoad), - bool const EP_UNUSED(RunFlag)) + void PlantProfileData::simulate(EnergyPlusData &state, + [[maybe_unused]] const PlantLocation &calledFromLocation, + [[maybe_unused]] bool const FirstHVACIteration, + [[maybe_unused]] Real64 &CurLoad, + [[maybe_unused]] bool const RunFlag) { // SUBROUTINE INFORMATION: diff --git a/src/EnergyPlus/PlantLoadProfile.hh b/src/EnergyPlus/PlantLoadProfile.hh index 71baac8f281..2eb0d54b967 100644 --- a/src/EnergyPlus/PlantLoadProfile.hh +++ b/src/EnergyPlus/PlantLoadProfile.hh @@ -123,9 +123,9 @@ namespace PlantLoadProfile { // Functions static PlantComponent *factory(EnergyPlusData &state, std::string objectName); - void simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, bool const FirstHVACIteration, Real64 &CurLoad, bool const RunFlag) override; + void simulate([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, bool const FirstHVACIteration, Real64 &CurLoad, bool const RunFlag) override; - void onInitLoopEquip(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation) override; + void onInitLoopEquip([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation) override; void InitPlantProfile(EnergyPlusData &state); diff --git a/src/EnergyPlus/PlantLoopHeatPumpEIR.cc b/src/EnergyPlus/PlantLoopHeatPumpEIR.cc index d0cad9d6868..c41df9d2369 100644 --- a/src/EnergyPlus/PlantLoopHeatPumpEIR.cc +++ b/src/EnergyPlus/PlantLoopHeatPumpEIR.cc @@ -352,7 +352,7 @@ namespace EIRPlantLoopHeatPumps { this->sourceSideOutletTemp = this->calcSourceOutletTemp(this->sourceSideInletTemp, this->sourceSideHeatTransfer / sourceMCp); } - void EIRPlantLoopHeatPump::onInitLoopEquip(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation)) + void EIRPlantLoopHeatPump::onInitLoopEquip(EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation) { // This function does all one-time and begin-environment initialization std::string const routineName = EIRPlantLoopHeatPumps::__EQUIP__ + ':' + __FUNCTION__; diff --git a/src/EnergyPlus/PlantLoopHeatPumpEIR.hh b/src/EnergyPlus/PlantLoopHeatPumpEIR.hh index cd8e6545a12..31476768c5b 100644 --- a/src/EnergyPlus/PlantLoopHeatPumpEIR.hh +++ b/src/EnergyPlus/PlantLoopHeatPumpEIR.hh @@ -145,13 +145,13 @@ namespace EIRPlantLoopHeatPumps { void simulate(EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; - void onInitLoopEquip(EnergyPlusData &EP_UNUSED(state), const PlantLocation &EP_UNUSED(calledFromLocation)) override; + void onInitLoopEquip([[maybe_unused]] EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation) override; void getDesignCapacities(EnergyPlusData &state, - const PlantLocation &EP_UNUSED(calledFromLocation), - Real64 &EP_UNUSED(MaxLoad), - Real64 &EP_UNUSED(MinLoad), - Real64 &EP_UNUSED(OptLoad)) override; + [[maybe_unused]] const PlantLocation &calledFromLocation, + [[maybe_unused]] Real64 &MaxLoad, + [[maybe_unused]] Real64 &MinLoad, + [[maybe_unused]] Real64 &OptLoad) override; void doPhysics(EnergyPlusData &state, Real64 currentLoad); diff --git a/src/EnergyPlus/PlantPipingSystemsManager.cc b/src/EnergyPlus/PlantPipingSystemsManager.cc index 27de65ba120..36172cf3d5a 100644 --- a/src/EnergyPlus/PlantPipingSystemsManager.cc +++ b/src/EnergyPlus/PlantPipingSystemsManager.cc @@ -157,7 +157,8 @@ namespace EnergyPlus { state.dataGlobal->AnyBasementsInModel = (numBasementsCheck > 0); } - PlantComponent *Circuit::factory(EnergyPlusData &state, int EP_UNUSED(objectType), std::string objectName) { + PlantComponent *Circuit::factory(EnergyPlusData &state, [[maybe_unused]] int objectType, std::string objectName) + { // Process the input data for circuits if it hasn't been done already if (GetInputFlag) { GetPipingSystemsAndGroundDomainsInput(state); @@ -176,10 +177,12 @@ namespace EnergyPlus { return nullptr; // LCOV_EXCL_LINE } - void Circuit::simulate(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation), - bool const EP_UNUSED(FirstHVACIteration), - Real64 &EP_UNUSED(CurLoad), - bool const EP_UNUSED(RunFlag)) { + void Circuit::simulate(EnergyPlusData &state, + [[maybe_unused]] const PlantLocation &calledFromLocation, + [[maybe_unused]] bool const FirstHVACIteration, + [[maybe_unused]] Real64 &CurLoad, + [[maybe_unused]] bool const RunFlag) + { // Retrieve the parent domain index for this pipe circuit auto &thisDomain(domains[this->ParentDomainIndex]); @@ -1478,15 +1481,14 @@ namespace EnergyPlus { } } - bool SiteGroundDomainUsingNoMassMat(EnergyPlusData &EP_UNUSED(state), Real64 const MaterialThickness, - int const MaterialNum) { + bool SiteGroundDomainUsingNoMassMat([[maybe_unused]] EnergyPlusData &state, Real64 const MaterialThickness, int const MaterialNum) + { if ( (MaterialThickness <= 0.0) || (dataMaterial.Material(MaterialNum).ROnly) ) { return true; } else { return false; } - } void SiteGroundDomainNoMassMatError(EnergyPlusData &state, std::string const &FieldName, @@ -2764,7 +2766,8 @@ namespace EnergyPlus { this->setupPipeCircuitInOutCells(); } - void Domain::createPartitionCenterList(EnergyPlusData &EP_UNUSED(state)) { + void Domain::createPartitionCenterList([[maybe_unused]] EnergyPlusData &state) + { // SUBROUTINE INFORMATION: // AUTHOR Edwin Lee diff --git a/src/EnergyPlus/PlantPipingSystemsManager.hh b/src/EnergyPlus/PlantPipingSystemsManager.hh index bfd620f8635..cdb0eab3af8 100644 --- a/src/EnergyPlus/PlantPipingSystemsManager.hh +++ b/src/EnergyPlus/PlantPipingSystemsManager.hh @@ -642,7 +642,7 @@ struct EnergyPlusData; static PlantComponent *factory(EnergyPlusData &state, int, std::string objectName); - void simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, + void simulate([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; bool operator==(std::string const & a) { diff --git a/src/EnergyPlus/PlantUtilities.cc b/src/EnergyPlus/PlantUtilities.cc index 5c0eeb3b717..fe7ffc53f6e 100644 --- a/src/EnergyPlus/PlantUtilities.cc +++ b/src/EnergyPlus/PlantUtilities.cc @@ -127,12 +127,12 @@ namespace PlantUtilities { void InitComponentNodes(Real64 const MinCompMdot, Real64 const MaxCompMdot, - int const InletNode, // component's inlet node index in node structure - int const OutletNode, // component's outlet node index in node structure - int const EP_UNUSED(LoopNum), // plant loop index for PlantLoop structure - int const EP_UNUSED(LoopSideNum), // Loop side index for PlantLoop structure - int const EP_UNUSED(BranchIndex), // branch index for PlantLoop - int const EP_UNUSED(CompIndex) // component index for PlantLoop + int const InletNode, // component's inlet node index in node structure + int const OutletNode, // component's outlet node index in node structure + [[maybe_unused]] int const LoopNum, // plant loop index for PlantLoop structure + [[maybe_unused]] int const LoopSideNum, // Loop side index for PlantLoop structure + [[maybe_unused]] int const BranchIndex, // branch index for PlantLoop + [[maybe_unused]] int const CompIndex // component index for PlantLoop ) { @@ -1049,15 +1049,15 @@ namespace PlantUtilities { } void UpdateChillerComponentCondenserSide(EnergyPlusData &state, - int const LoopNum, // component's loop index - int const LoopSide, // component's loop side number - int const EP_UNUSED(TypeOfNum), // Component's type index - int const InletNodeNum, // Component's inlet node pointer - int const OutletNodeNum, // Component's outlet node pointer - Real64 const ModelCondenserHeatRate, // model's heat rejection rate at condenser (W) - Real64 const ModelInletTemp, // model's inlet temperature (C) - Real64 const ModelOutletTemp, // model's outlet temperature (C) - Real64 const ModelMassFlowRate, // model's condenser water mass flow rate (kg/s) + int const LoopNum, // component's loop index + int const LoopSide, // component's loop side number + [[maybe_unused]] int const TypeOfNum, // Component's type index + int const InletNodeNum, // Component's inlet node pointer + int const OutletNodeNum, // Component's outlet node pointer + Real64 const ModelCondenserHeatRate, // model's heat rejection rate at condenser (W) + Real64 const ModelInletTemp, // model's inlet temperature (C) + Real64 const ModelOutletTemp, // model's outlet temperature (C) + Real64 const ModelMassFlowRate, // model's condenser water mass flow rate (kg/s) bool const FirstHVACIteration) { @@ -1137,15 +1137,15 @@ namespace PlantUtilities { } void UpdateComponentHeatRecoverySide(EnergyPlusData &state, - int const LoopNum, // component's loop index - int const LoopSide, // component's loop side number - int const EP_UNUSED(TypeOfNum), // Component's type index - int const InletNodeNum, // Component's inlet node pointer - int const OutletNodeNum, // Component's outlet node pointer - Real64 const ModelRecoveryHeatRate, // model's heat rejection rate at recovery (W) - Real64 const ModelInletTemp, // model's inlet temperature (C) - Real64 const ModelOutletTemp, // model's outlet temperature (C) - Real64 const ModelMassFlowRate, // model's condenser water mass flow rate (kg/s) + int const LoopNum, // component's loop index + int const LoopSide, // component's loop side number + [[maybe_unused]] int const TypeOfNum, // Component's type index + int const InletNodeNum, // Component's inlet node pointer + int const OutletNodeNum, // Component's outlet node pointer + Real64 const ModelRecoveryHeatRate, // model's heat rejection rate at recovery (W) + Real64 const ModelInletTemp, // model's inlet temperature (C) + Real64 const ModelOutletTemp, // model's outlet temperature (C) + Real64 const ModelMassFlowRate, // model's condenser water mass flow rate (kg/s) bool const FirstHVACIteration) { @@ -1223,14 +1223,14 @@ namespace PlantUtilities { } } - void UpdateAbsorberChillerComponentGeneratorSide(int const LoopNum, // component's loop index - int const LoopSide, // component's loop side number - int const EP_UNUSED(TypeOfNum), // Component's type index - int const InletNodeNum, // Component's inlet node pointer - int const EP_UNUSED(OutletNodeNum), // Component's outlet node pointer - int const EP_UNUSED(HeatSourceType), // Type of fluid in Generator loop - Real64 const ModelGeneratorHeatRate, // model's generator heat rate (W) - Real64 const ModelMassFlowRate, // model's generator mass flow rate (kg/s) + void UpdateAbsorberChillerComponentGeneratorSide(int const LoopNum, // component's loop index + int const LoopSide, // component's loop side number + [[maybe_unused]] int const TypeOfNum, // Component's type index + int const InletNodeNum, // Component's inlet node pointer + [[maybe_unused]] int const OutletNodeNum, // Component's outlet node pointer + [[maybe_unused]] int const HeatSourceType, // Type of fluid in Generator loop + Real64 const ModelGeneratorHeatRate, // model's generator heat rate (W) + Real64 const ModelMassFlowRate, // model's generator mass flow rate (kg/s) bool const FirstHVACIteration) { @@ -1507,7 +1507,7 @@ namespace PlantUtilities { void SafeCopyPlantNode(int const InletNodeNum, int const OutletNodeNum, Optional_int_const LoopNum, - Optional EP_UNUSED(OutletTemp) // set on outlet node if present and water. + [[maybe_unused]] Optional OutletTemp // set on outlet node if present and water. ) { @@ -2077,12 +2077,13 @@ namespace PlantUtilities { } } - int MyPlantSizingIndex(EnergyPlusData &state, std::string const &CompType, // component description - std::string const &CompName, // user name of component - int const NodeNumIn, // component water inlet node - int const EP_UNUSED(NodeNumOut), // component water outlet node - bool &ErrorsFound, // set to true if there's an error, unchanged otherwise - Optional_bool_const SupressErrors // used for WSHP's where condenser loop may not be on a plant loop + int MyPlantSizingIndex(EnergyPlusData &state, + std::string const &CompType, // component description + std::string const &CompName, // user name of component + int const NodeNumIn, // component water inlet node + [[maybe_unused]] int const NodeNumOut, // component water outlet node + bool &ErrorsFound, // set to true if there's an error, unchanged otherwise + Optional_bool_const SupressErrors // used for WSHP's where condenser loop may not be on a plant loop ) { diff --git a/src/EnergyPlus/PlantValves.cc b/src/EnergyPlus/PlantValves.cc index 12d370a89a6..b0a67d33bdb 100644 --- a/src/EnergyPlus/PlantValves.cc +++ b/src/EnergyPlus/PlantValves.cc @@ -121,8 +121,12 @@ namespace PlantValves { TemperValve.deallocate(); } - void TemperValveData::simulate(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation), bool EP_UNUSED(FirstHVACIteration), Real64 &EP_UNUSED(CurLoad), - bool EP_UNUSED(RunFlag)) { + void TemperValveData::simulate(EnergyPlusData &state, + [[maybe_unused]] const PlantLocation &calledFromLocation, + [[maybe_unused]] bool FirstHVACIteration, + [[maybe_unused]] Real64 &CurLoad, + [[maybe_unused]] bool RunFlag) + { this->initialize(state); this->calculate(state); PlantUtilities::SafeCopyPlantNode(this->PltInletNodeNum, this->PltOutletNodeNum); @@ -140,8 +144,8 @@ namespace PlantValves { } } - void TemperValveData::getDesignCapacities(EnergyPlusData &EP_UNUSED(state), - const PlantLocation &EP_UNUSED(calledFromLocation), + void TemperValveData::getDesignCapacities([[maybe_unused]] EnergyPlusData &state, + [[maybe_unused]] const PlantLocation &calledFromLocation, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) diff --git a/src/EnergyPlus/PlantValves.hh b/src/EnergyPlus/PlantValves.hh index 06075b388a3..e531a84f8a0 100644 --- a/src/EnergyPlus/PlantValves.hh +++ b/src/EnergyPlus/PlantValves.hh @@ -96,7 +96,7 @@ namespace PlantValves { static PlantComponent *factory(EnergyPlusData &state, std::string objectName); - void simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, + void simulate([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; void getDesignCapacities(EnergyPlusData &state, diff --git a/src/EnergyPlus/PluginManager.cc b/src/EnergyPlus/PluginManager.cc index 1e64a1ca9d6..a7b739ca0c3 100644 --- a/src/EnergyPlus/PluginManager.cc +++ b/src/EnergyPlus/PluginManager.cc @@ -84,7 +84,7 @@ namespace PluginManagement { } } - void registerNewCallback(EnergyPlusData &EP_UNUSED(state), EMSManager::EMSCallFrom iCalledFrom, const std::function &f) + void registerNewCallback([[maybe_unused]] EnergyPlusData &state, EMSManager::EMSCallFrom iCalledFrom, const std::function &f) { callbacks[iCalledFrom].push_back(f); } @@ -645,7 +645,7 @@ namespace PluginManagement { return sanitizedDir; } #else - std::string PluginManager::sanitizedPath(std::string EP_UNUSED(path)) + std::string PluginManager::sanitizedPath([[maybe_unused]] std::string path) { return ""; } @@ -1071,7 +1071,7 @@ namespace PluginManagement { return true; } #else - bool PluginInstance::run(EnergyPlusData &EP_UNUSED(state), EMSManager::EMSCallFrom EP_UNUSED(iCalledFrom)) const + bool PluginInstance::run([[maybe_unused]] EnergyPlusData &state, [[maybe_unused]] EMSManager::EMSCallFrom iCalledFrom) const { return false; } @@ -1093,7 +1093,7 @@ namespace PluginManagement { } } #else - void PluginManager::addToPythonPath(EnergyPlusData &state, const std::string &EP_UNUSED(path), bool EP_UNUSED(userDefinedPath)) + void PluginManager::addToPythonPath(EnergyPlusData &state, [[maybe_unused]] const std::string &path, [[maybe_unused]] bool userDefinedPath) { } #endif @@ -1107,7 +1107,7 @@ namespace PluginManagement { this->maxGlobalVariableIndex++; } #else - void PluginManager::addGlobalVariable(const std::string &EP_UNUSED(name)) + void PluginManager::addGlobalVariable([[maybe_unused]] const std::string &name) { } #endif @@ -1134,7 +1134,9 @@ namespace PluginManagement { } } #else - int PluginManager::getGlobalVariableHandle(EnergyPlusData &state, const std::string &EP_UNUSED(name), bool const EP_UNUSED(suppress_warning)) + int PluginManager::getGlobalVariableHandle(EnergyPlusData &state, + [[maybe_unused]] const std::string &name, + [[maybe_unused]] bool const suppress_warning) { return -1; } @@ -1153,7 +1155,7 @@ namespace PluginManagement { return -1; } #else - int PluginManager::getTrendVariableHandle(const std::string &EP_UNUSED(name)) + int PluginManager::getTrendVariableHandle([[maybe_unused]] const std::string &name) { return -1; } @@ -1165,7 +1167,7 @@ namespace PluginManagement { return trends[handle].values[timeIndex]; } #else - Real64 PluginManager::getTrendVariableValue(int EP_UNUSED(handle), int EP_UNUSED(timeIndex)) + Real64 PluginManager::getTrendVariableValue([[maybe_unused]] int handle, [[maybe_unused]] int timeIndex) { return 0.0; } @@ -1181,7 +1183,7 @@ namespace PluginManagement { return sum / count; } #else - Real64 PluginManager::getTrendVariableAverage(int EP_UNUSED(handle), int EP_UNUSED(count)) + Real64 PluginManager::getTrendVariableAverage([[maybe_unused]] int handle, [[maybe_unused]] int count) { return 0.0; } @@ -1199,7 +1201,7 @@ namespace PluginManagement { return minimumValue; } #else - Real64 PluginManager::getTrendVariableMin(int EP_UNUSED(handle), int EP_UNUSED(count)) + Real64 PluginManager::getTrendVariableMin([[maybe_unused]] int handle, [[maybe_unused]] int count) { return 0.0; } @@ -1217,7 +1219,7 @@ namespace PluginManagement { return maximumValue; } #else - Real64 PluginManager::getTrendVariableMax(int EP_UNUSED(handle), int EP_UNUSED(count)) + Real64 PluginManager::getTrendVariableMax([[maybe_unused]] int handle, [[maybe_unused]] int count) { return 0.0; } @@ -1233,7 +1235,7 @@ namespace PluginManagement { return sum; } #else - Real64 PluginManager::getTrendVariableSum(int EP_UNUSED(handle), int EP_UNUSED(count)) + Real64 PluginManager::getTrendVariableSum([[maybe_unused]] int handle, [[maybe_unused]] int count) { return 0.0; } @@ -1258,7 +1260,7 @@ namespace PluginManagement { return numerator / denominator; } #else - Real64 PluginManager::getTrendVariableDirection(int EP_UNUSED(handle), int EP_UNUSED(count)) + Real64 PluginManager::getTrendVariableDirection([[maybe_unused]] int handle, [[maybe_unused]] int count) { return 0.0; } @@ -1270,7 +1272,7 @@ namespace PluginManagement { return trends[handle].values.size(); } #else - size_t PluginManager::getTrendVariableHistorySize(int EP_UNUSED(handle)) + size_t PluginManager::getTrendVariableHistorySize([[maybe_unused]] int handle) { return 0; } @@ -1304,7 +1306,7 @@ namespace PluginManagement { return 0.0; } #else - Real64 PluginManager::getGlobalVariableValue(EnergyPlusData &state, int EP_UNUSED(handle)) + Real64 PluginManager::getGlobalVariableValue(EnergyPlusData &state, [[maybe_unused]] int handle) { return 0.0; } @@ -1326,7 +1328,7 @@ namespace PluginManagement { } } #else - void PluginManager::setGlobalVariableValue(EnergyPlusData &state, int EP_UNUSED(handle), Real64 EP_UNUSED(value)) + void PluginManager::setGlobalVariableValue(EnergyPlusData &state, [[maybe_unused]] int handle, [[maybe_unused]] Real64 value) { } #endif @@ -1343,7 +1345,7 @@ namespace PluginManagement { return -1; } #else - int PluginManager::getLocationOfUserDefinedPlugin(std::string const &EP_UNUSED(programName)) + int PluginManager::getLocationOfUserDefinedPlugin([[maybe_unused]] std::string const &programName) { return -1; } @@ -1355,7 +1357,7 @@ namespace PluginManagement { plugins[index].run(state, EMSManager::EMSCallFrom::UserDefinedComponentModel); } #else - void PluginManager::runSingleUserDefinedPlugin(EnergyPlusData &EP_UNUSED(state), int EP_UNUSED(index)) + void PluginManager::runSingleUserDefinedPlugin([[maybe_unused]] EnergyPlusData &state, [[maybe_unused]] int index) { } #endif diff --git a/src/EnergyPlus/PondGroundHeatExchanger.cc b/src/EnergyPlus/PondGroundHeatExchanger.cc index 6d7a26c36c1..183dc6241fb 100644 --- a/src/EnergyPlus/PondGroundHeatExchanger.cc +++ b/src/EnergyPlus/PondGroundHeatExchanger.cc @@ -128,10 +128,11 @@ namespace PondGroundHeatExchanger { PondGHE.clear(); } - void PondGroundHeatExchangerData::simulate(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation), + void PondGroundHeatExchangerData::simulate(EnergyPlusData &state, + [[maybe_unused]] const PlantLocation &calledFromLocation, bool const FirstHVACIteration, - Real64 &EP_UNUSED(CurLoad), - bool const EP_UNUSED(RunFlag)) + [[maybe_unused]] Real64 &CurLoad, + [[maybe_unused]] bool const RunFlag) { this->InitPondGroundHeatExchanger(state, FirstHVACIteration); this->CalcPondGroundHeatExchanger(state); @@ -155,13 +156,13 @@ namespace PondGroundHeatExchanger { return nullptr; } - void PondGroundHeatExchangerData::onInitLoopEquip(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation)) + void PondGroundHeatExchangerData::onInitLoopEquip(EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation) { this->InitPondGroundHeatExchanger(state, true); } - void PondGroundHeatExchangerData::getDesignCapacities(EnergyPlusData &EP_UNUSED(state), - const PlantLocation &EP_UNUSED(calledFromLocation), + void PondGroundHeatExchangerData::getDesignCapacities([[maybe_unused]] EnergyPlusData &state, + [[maybe_unused]] const PlantLocation &calledFromLocation, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) diff --git a/src/EnergyPlus/PondGroundHeatExchanger.hh b/src/EnergyPlus/PondGroundHeatExchanger.hh index 791b83b7141..fc93d6cc020 100644 --- a/src/EnergyPlus/PondGroundHeatExchanger.hh +++ b/src/EnergyPlus/PondGroundHeatExchanger.hh @@ -145,7 +145,7 @@ namespace PondGroundHeatExchanger { void UpdatePondGroundHeatExchanger(EnergyPlusData &state); - void onInitLoopEquip(EnergyPlusData &EP_UNUSED(state), const PlantLocation &EP_UNUSED(calledFromLocation)) override; + void onInitLoopEquip([[maybe_unused]] EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation) override; }; diff --git a/src/EnergyPlus/Psychrometrics.hh b/src/EnergyPlus/Psychrometrics.hh index 39585f5a327..08bc9963b25 100644 --- a/src/EnergyPlus/Psychrometrics.hh +++ b/src/EnergyPlus/Psychrometrics.hh @@ -289,7 +289,7 @@ namespace Psychrometrics { return rhoair; } - inline Real64 PsyHfgAirFnWTdb(Real64 const EP_UNUSED(w), // humidity ratio {kgWater/kgDryAir} !unused1208 + inline Real64 PsyHfgAirFnWTdb([[maybe_unused]] Real64 const w, // humidity ratio {kgWater/kgDryAir} !unused1208 Real64 const T // input temperature {Celsius} ) { @@ -319,7 +319,7 @@ namespace Psychrometrics { return (2500940.0 + 1858.95 * Temperature) - (4180.0 * Temperature); // enthalpy of the gas - enthalpy of the fluid } - inline Real64 PsyHgAirFnWTdb(Real64 const EP_UNUSED(w), // humidity ratio {kgWater/kgDryAir} !unused1208 + inline Real64 PsyHgAirFnWTdb([[maybe_unused]] Real64 const w, // humidity ratio {kgWater/kgDryAir} !unused1208 Real64 const T // input temperature {Celsius} ) { @@ -1251,7 +1251,7 @@ namespace Psychrometrics { return (A0 + X * (A1 + X * (A2 + X * (A3 + X * (A4 + X * (A5 + X * A6)))))) / 1.0E10; } - inline Real64 CPCW(Real64 const EP_UNUSED(Temperature) // unused1208 + inline Real64 CPCW([[maybe_unused]] Real64 const Temperature // unused1208 ) { // FUNCTION INFORMATION: @@ -1264,7 +1264,7 @@ namespace Psychrometrics { return 4180.0; } - inline Real64 CPHW(Real64 const EP_UNUSED(Temperature) // unused1208 + inline Real64 CPHW([[maybe_unused]] Real64 const Temperature // unused1208 ) { // FUNCTION INFORMATION: diff --git a/src/EnergyPlus/PurchasedAirManager.cc b/src/EnergyPlus/PurchasedAirManager.cc index b9c094882e1..6b58815637e 100644 --- a/src/EnergyPlus/PurchasedAirManager.cc +++ b/src/EnergyPlus/PurchasedAirManager.cc @@ -1090,7 +1090,7 @@ namespace PurchasedAirManager { void InitPurchasedAir(EnergyPlusData &state, int const PurchAirNum, - bool const EP_UNUSED(FirstHVACIteration), // unused1208 + [[maybe_unused]] bool const FirstHVACIteration, // unused1208 int const ControlledZoneNum, int const ActualZoneNum) { diff --git a/src/EnergyPlus/RefrigeratedCase.cc b/src/EnergyPlus/RefrigeratedCase.cc index 9189585abe0..3afe14ae4a3 100644 --- a/src/EnergyPlus/RefrigeratedCase.cc +++ b/src/EnergyPlus/RefrigeratedCase.cc @@ -10164,16 +10164,17 @@ namespace RefrigeratedCase { return nullptr; // LCOV_EXCL_LINE } - void RefrigCondenserData::onInitLoopEquip(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation)) + void RefrigCondenserData::onInitLoopEquip(EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation) { InitRefrigeration(state); InitRefrigerationPlantConnections(state); } - void RefrigCondenserData::simulate(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation), + void RefrigCondenserData::simulate(EnergyPlusData &state, + [[maybe_unused]] const PlantLocation &calledFromLocation, bool const FirstHVACIteration, - Real64 &EP_UNUSED(CurLoad), - bool const EP_UNUSED(RunFlag)) + [[maybe_unused]] Real64 &CurLoad, + [[maybe_unused]] bool const RunFlag) { // SUBROUTINE INFORMATION: @@ -10321,142 +10322,144 @@ namespace RefrigeratedCase { return nullptr; // LCOV_EXCL_LINE } - void RefrigRackData::onInitLoopEquip(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation)) - { + void RefrigRackData::onInitLoopEquip(EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation) + { InitRefrigeration(state); InitRefrigerationPlantConnections(state); } - void RefrigRackData::simulate(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation), - bool const FirstHVACIteration, - Real64 &EP_UNUSED(CurLoad), - bool const EP_UNUSED(RunFlag)) - { - - // SUBROUTINE INFORMATION: - // AUTHOR Randy Hudson, ORNL - // DATE WRITTEN July 2007 - // MODIFIED Therese Stovall, ORNL May 2008 - // Brent Griffith, NREL Oct 2010, generalize fluid properties - // plant upgrades, moved where called from to SimPlantEquip from ManageNonZoneEquipment - // RE-ENGINEERED na - - // PURPOSE OF THIS SUBROUTINE: - // Simulates the water-cooled refrigeration condenser object. - // Modified to add condensers for detailed refrigeration systems and to - // avoid double-counting heat rejection that has been used in desuperheater - // hvac coils or water heaters. - - // METHODOLOGY EMPLOYED: - // Called from SimPlantEquip in PlantLoopEquipment , previously was called from Non-Zone Equipment Manager - // Flow is requested and the actual available flow is set. The outlet temperature is calculated. - - static std::string const RoutineName("SimRefrigCondenser"); - int PlantInletNode(0); - int PlantOutletNode(0); - int PlantLoopIndex(0); - int PlantLoopSideIndex(0); - int PlantBranchIndex(0); - int PlantCompIndex(0); - - InitRefrigerationPlantConnections(state); - - std::string TypeName; - std::string ErrIntro; - - // set variables depending upon system type - PlantInletNode = this->InletNode; - PlantOutletNode = this->OutletNode; - PlantLoopIndex = this->PlantLoopNum; - PlantLoopSideIndex = this->PlantLoopSideNum; - PlantBranchIndex = this->PlantBranchNum; - PlantCompIndex = this->PlantCompNum; - - TotalCondenserHeat = - DataHeatBalance::HeatReclaimRefrigeratedRack(this->MyIdx).AvailCapacity - this->LaggedUsedWaterHeater - this->LaggedUsedHVACCoil; - TypeName = "Refrigeration:CompressorRack:"; - ErrIntro = "Condenser for refrigeration rack "; - - // Current condenser is water cooled - // Make demand request on first HVAC iteration - - // get cooling fluid properties - Real64 rho = FluidProperties::GetDensityGlycol( - state, DataPlant::PlantLoop(PlantLoopIndex).FluidName, this->InletTemp, DataPlant::PlantLoop(PlantLoopIndex).FluidIndex, RoutineName); - Real64 Cp = FluidProperties::GetSpecificHeatGlycol( - state, DataPlant::PlantLoop(PlantLoopIndex).FluidName, this->InletTemp, DataPlant::PlantLoop(PlantLoopIndex).FluidIndex, RoutineName); + void RefrigRackData::simulate(EnergyPlusData &state, + [[maybe_unused]] const PlantLocation &calledFromLocation, + bool const FirstHVACIteration, + [[maybe_unused]] Real64 &CurLoad, + [[maybe_unused]] bool const RunFlag) + { - if (this->FlowType == VariableFlow && TotalCondenserHeat > 0.0) { - this->OutletTemp = ScheduleManager::GetCurrentScheduleValue(state, this->OutletTempSchedPtr); + // SUBROUTINE INFORMATION: + // AUTHOR Randy Hudson, ORNL + // DATE WRITTEN July 2007 + // MODIFIED Therese Stovall, ORNL May 2008 + // Brent Griffith, NREL Oct 2010, generalize fluid properties + // plant upgrades, moved where called from to SimPlantEquip from ManageNonZoneEquipment + // RE-ENGINEERED na + + // PURPOSE OF THIS SUBROUTINE: + // Simulates the water-cooled refrigeration condenser object. + // Modified to add condensers for detailed refrigeration systems and to + // avoid double-counting heat rejection that has been used in desuperheater + // hvac coils or water heaters. + + // METHODOLOGY EMPLOYED: + // Called from SimPlantEquip in PlantLoopEquipment , previously was called from Non-Zone Equipment Manager + // Flow is requested and the actual available flow is set. The outlet temperature is calculated. + + static std::string const RoutineName("SimRefrigCondenser"); + int PlantInletNode(0); + int PlantOutletNode(0); + int PlantLoopIndex(0); + int PlantLoopSideIndex(0); + int PlantBranchIndex(0); + int PlantCompIndex(0); - if (this->OutletTemp == this->InletTemp) { + InitRefrigerationPlantConnections(state); - if (this->HighInletWarnIndex == 0) { - ShowSevereError(state, ErrIntro + ", \"" + this->Name + - "\" : has inlet water temp equal to desired outlet temp. Excessive flow resulting. "); - ShowContinueError(state, "cooling water is not cold enough to reach desired outlet temperature"); - } - ShowRecurringWarningErrorAtEnd(state, ErrIntro + ", \"" + this->Name + - "\" : has inlet water temp equal to desired outlet temp.... continues. ", - this->HighInletWarnIndex); - this->VolFlowRate = 9999.0; + std::string TypeName; + std::string ErrIntro; + + // set variables depending upon system type + PlantInletNode = this->InletNode; + PlantOutletNode = this->OutletNode; + PlantLoopIndex = this->PlantLoopNum; + PlantLoopSideIndex = this->PlantLoopSideNum; + PlantBranchIndex = this->PlantBranchNum; + PlantCompIndex = this->PlantCompNum; + + TotalCondenserHeat = + DataHeatBalance::HeatReclaimRefrigeratedRack(this->MyIdx).AvailCapacity - this->LaggedUsedWaterHeater - this->LaggedUsedHVACCoil; + TypeName = "Refrigeration:CompressorRack:"; + ErrIntro = "Condenser for refrigeration rack "; + + // Current condenser is water cooled + // Make demand request on first HVAC iteration + + // get cooling fluid properties + Real64 rho = FluidProperties::GetDensityGlycol( + state, DataPlant::PlantLoop(PlantLoopIndex).FluidName, this->InletTemp, DataPlant::PlantLoop(PlantLoopIndex).FluidIndex, RoutineName); + Real64 Cp = FluidProperties::GetSpecificHeatGlycol( + state, DataPlant::PlantLoop(PlantLoopIndex).FluidName, this->InletTemp, DataPlant::PlantLoop(PlantLoopIndex).FluidIndex, RoutineName); + + if (this->FlowType == VariableFlow && TotalCondenserHeat > 0.0) { + this->OutletTemp = ScheduleManager::GetCurrentScheduleValue(state, this->OutletTempSchedPtr); + + if (this->OutletTemp == this->InletTemp) { + + if (this->HighInletWarnIndex == 0) { + ShowSevereError(state, + ErrIntro + ", \"" + this->Name + + "\" : has inlet water temp equal to desired outlet temp. Excessive flow resulting. "); + ShowContinueError(state, "cooling water is not cold enough to reach desired outlet temperature"); + } + ShowRecurringWarningErrorAtEnd(state, ErrIntro + ", \"" + this->Name + + "\" : has inlet water temp equal to desired outlet temp.... continues. ", + this->HighInletWarnIndex); + this->VolFlowRate = 9999.0; + this->MassFlowRate = this->VolFlowRate * rho; + } else { + Real64 DeltaT = this->OutletTemp - this->InletTemp; + this->MassFlowRate = TotalCondenserHeat / Cp / DeltaT; + // Check for maximum flow in the component + if (this->MassFlowRate > this->MassFlowRateMax) { + if (this->HighFlowWarnIndex == 0) { + ShowWarningMessage(state, TypeName + this->Name); + ShowContinueError(state, "Requested condenser water mass flow rate greater than maximum allowed value. "); + ShowContinueError(state, "Flow reset to maximum value."); + } // HighFlowWarnIndex + ShowRecurringWarningErrorAtEnd(state, ErrIntro + this->Name + " - Flow rate higher than maximum allowed ... continues", + this->HighFlowWarnIndex); + // END IF + this->MassFlowRate = this->MassFlowRateMax; + } + } // compare outlet T to inlet T + + } else if (this->FlowType == ConstantFlow && TotalCondenserHeat > 0.0) { + // this part for constant flow condition + this->VolFlowRate = this->DesVolFlowRate; this->MassFlowRate = this->VolFlowRate * rho; - } else { - Real64 DeltaT = this->OutletTemp - this->InletTemp; - this->MassFlowRate = TotalCondenserHeat / Cp / DeltaT; - // Check for maximum flow in the component - if (this->MassFlowRate > this->MassFlowRateMax) { - if (this->HighFlowWarnIndex == 0) { - ShowWarningMessage(state, TypeName + this->Name); - ShowContinueError(state, "Requested condenser water mass flow rate greater than maximum allowed value. "); - ShowContinueError(state, "Flow reset to maximum value."); - } // HighFlowWarnIndex - ShowRecurringWarningErrorAtEnd(state, ErrIntro + this->Name + " - Flow rate higher than maximum allowed ... continues", - this->HighFlowWarnIndex); - // END IF - this->MassFlowRate = this->MassFlowRateMax; - } - } // compare outlet T to inlet T - } else if (this->FlowType == ConstantFlow && TotalCondenserHeat > 0.0) { - // this part for constant flow condition - this->VolFlowRate = this->DesVolFlowRate; - this->MassFlowRate = this->VolFlowRate * rho; + } else if (TotalCondenserHeat == 0.0) { + this->MassFlowRate = 0.0; - } else if (TotalCondenserHeat == 0.0) { - this->MassFlowRate = 0.0; - - } // on flow type - // check against plant, might get changed. - PlantUtilities::SetComponentFlowRate(state, - this->MassFlowRate, PlantInletNode, PlantOutletNode, PlantLoopIndex, PlantLoopSideIndex, PlantBranchIndex, PlantCompIndex); + } // on flow type + // check against plant, might get changed. + PlantUtilities::SetComponentFlowRate( + state, this->MassFlowRate, PlantInletNode, PlantOutletNode, PlantLoopIndex, PlantLoopSideIndex, PlantBranchIndex, PlantCompIndex); - this->VolFlowRate = this->MassFlowRate / rho; + this->VolFlowRate = this->MassFlowRate / rho; - if (this->MassFlowRate > 0) { - this->OutletTemp = TotalCondenserHeat / (this->MassFlowRate * Cp) + DataLoopNode::Node(PlantInletNode).Temp; - } else { - this->OutletTemp = this->InletTemp; - if ((TotalCondenserHeat > 0.0) && (!FirstHVACIteration)) { + if (this->MassFlowRate > 0) { + this->OutletTemp = TotalCondenserHeat / (this->MassFlowRate * Cp) + DataLoopNode::Node(PlantInletNode).Temp; + } else { + this->OutletTemp = this->InletTemp; + if ((TotalCondenserHeat > 0.0) && (!FirstHVACIteration)) { - ShowRecurringWarningErrorAtEnd(state, - TypeName + this->Name + - "Water-cooled condenser has no cooling water flow. Heat is not being rejected from compressor rack condenser.", - this->NoFlowWarnIndex); + ShowRecurringWarningErrorAtEnd(state, + TypeName + this->Name + + "Water-cooled condenser has no cooling water flow. Heat is not being rejected from compressor rack condenser.", + this->NoFlowWarnIndex); + } } - } - // Check outlet water temp for max value - if (this->OutletTemp > this->OutletTempMax) { - if (this->HighTempWarnIndex == 0) { - ShowWarningMessage(state, TypeName + this->Name); - ShowContinueError(state, - "Water-cooled condenser outlet temp higher than maximum allowed temp. Check flow rates and/or temperature setpoints."); + // Check outlet water temp for max value + if (this->OutletTemp > this->OutletTempMax) { + if (this->HighTempWarnIndex == 0) { + ShowWarningMessage(state, TypeName + this->Name); + ShowContinueError( + state, "Water-cooled condenser outlet temp higher than maximum allowed temp. Check flow rates and/or temperature setpoints."); + } + ShowRecurringWarningErrorAtEnd(state, ErrIntro + this->Name + " - Condenser outlet temp higher than maximum allowed ... continues", + HighTempWarnIndex); } - ShowRecurringWarningErrorAtEnd(state, ErrIntro + this->Name + " - Condenser outlet temp higher than maximum allowed ... continues", - HighTempWarnIndex); - } - this->UpdateCondenser(); + this->UpdateCondenser(); } void RefrigCondenserData::UpdateCondenser() diff --git a/src/EnergyPlus/RefrigeratedCase.hh b/src/EnergyPlus/RefrigeratedCase.hh index b011fb84c40..7828c8e32f5 100644 --- a/src/EnergyPlus/RefrigeratedCase.hh +++ b/src/EnergyPlus/RefrigeratedCase.hh @@ -371,9 +371,9 @@ namespace RefrigeratedCase { static PlantComponent *factory(EnergyPlusData &state, std::string const &objectName); - void onInitLoopEquip(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation) override; + void onInitLoopEquip([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation) override; - void simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; + void simulate([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; }; struct RefrigSystemData @@ -865,9 +865,9 @@ namespace RefrigeratedCase { static PlantComponent *factory(EnergyPlusData &state, std::string const &objectName); - void onInitLoopEquip(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation) override; + void onInitLoopEquip([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation) override; - void simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; + void simulate([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; }; struct RefrigGasCoolerData diff --git a/src/EnergyPlus/ReturnAirPathManager.cc b/src/EnergyPlus/ReturnAirPathManager.cc index bc5937b82c0..c42c1bc5acc 100644 --- a/src/EnergyPlus/ReturnAirPathManager.cc +++ b/src/EnergyPlus/ReturnAirPathManager.cc @@ -245,7 +245,7 @@ namespace ReturnAirPathManager { } } - void InitReturnAirPath(int &EP_UNUSED(ReturnAirPathNum)) // unused1208 + void InitReturnAirPath([[maybe_unused]] int &ReturnAirPathNum) // unused1208 { // SUBROUTINE INFORMATION: // AUTHOR: Russ Taylor @@ -309,7 +309,7 @@ namespace ReturnAirPathManager { } } - void ReportReturnAirPath(int &EP_UNUSED(ReturnAirPathNum)) // unused1208 + void ReportReturnAirPath([[maybe_unused]] int &ReturnAirPathNum) // unused1208 { // SUBROUTINE INFORMATION: // AUTHOR: Russ Taylor diff --git a/src/EnergyPlus/RoomAirModelAirflowNetwork.cc b/src/EnergyPlus/RoomAirModelAirflowNetwork.cc index 33942c6766c..99e279e4f6a 100644 --- a/src/EnergyPlus/RoomAirModelAirflowNetwork.cc +++ b/src/EnergyPlus/RoomAirModelAirflowNetwork.cc @@ -1147,8 +1147,12 @@ namespace RoomAirModelAirflowNetwork { } // CalcNodeSums - void RAFNData::CalcSurfaceMoistureSums( - EnergyPlusData &state, int const RoomAirNode, Real64 &SumHmAW, Real64 &SumHmARa, Real64 &SumHmARaW, Array1D const &EP_UNUSED(SurfMask)) + void RAFNData::CalcSurfaceMoistureSums(EnergyPlusData &state, + int const RoomAirNode, + Real64 &SumHmAW, + Real64 &SumHmARa, + Real64 &SumHmARaW, + [[maybe_unused]] Array1D const &SurfMask) { // SUBROUTINE INFORMATION: diff --git a/src/EnergyPlus/SQLiteProcedures.cc b/src/EnergyPlus/SQLiteProcedures.cc index 2c15df2eda9..31ea928329b 100644 --- a/src/EnergyPlus/SQLiteProcedures.cc +++ b/src/EnergyPlus/SQLiteProcedures.cc @@ -1508,7 +1508,7 @@ void SQLite::createSQLiteReportDataRecord(int const recordIndex, } void SQLite::createSQLiteTimeIndexRecord(int const reportingInterval, - int const EP_UNUSED(recordIndex), + [[maybe_unused]] int const recordIndex, int const cumlativeSimulationDays, int const curEnvirNum, int const simulationYear, diff --git a/src/EnergyPlus/SZVAVModel.cc b/src/EnergyPlus/SZVAVModel.cc index 5c8468e903b..ad4b40ac21c 100644 --- a/src/EnergyPlus/SZVAVModel.cc +++ b/src/EnergyPlus/SZVAVModel.cc @@ -507,14 +507,15 @@ namespace SZVAVModel { } } - void calcSZVAVModel(EnergyPlusData &state, FanCoilUnits::FanCoilData &SZVAVModel, + void calcSZVAVModel(EnergyPlusData &state, + FanCoilUnits::FanCoilData &SZVAVModel, int const &SysIndex, bool const &FirstHVACIteration, bool const &CoolingLoad, bool const &HeatingLoad, Real64 const &ZoneLoad, Real64 &OnOffAirFlowRatio, - bool const &EP_UNUSED(HXUnitOn), + [[maybe_unused]] bool const &HXUnitOn, int const &AirLoopNum, Real64 &PartLoadRatio, int const &CompressorONFlag) diff --git a/src/EnergyPlus/SetPointManager.cc b/src/EnergyPlus/SetPointManager.cc index 0e6d862ee9d..70a9fbd5fd0 100644 --- a/src/EnergyPlus/SetPointManager.cc +++ b/src/EnergyPlus/SetPointManager.cc @@ -3667,7 +3667,7 @@ namespace SetPointManager { lNumericFieldBlanks.deallocate(); } - void VerifySetPointManagers(EnergyPlusData &state, bool &EP_UNUSED(ErrorsFound)) // flag to denote node conflicts in input. !unused1208 + void VerifySetPointManagers(EnergyPlusData &state, [[maybe_unused]] bool &ErrorsFound) // flag to denote node conflicts in input. !unused1208 { // SUBROUTINE INFORMATION: diff --git a/src/EnergyPlus/SingleDuct.cc b/src/EnergyPlus/SingleDuct.cc index 41f2b45f24a..f0efc33b92b 100644 --- a/src/EnergyPlus/SingleDuct.cc +++ b/src/EnergyPlus/SingleDuct.cc @@ -4822,15 +4822,15 @@ namespace SingleDuct { } void SingleDuctAirTerminal::CalcVAVVS(EnergyPlusData &state, - bool const FirstHVACIteration, // flag for 1st HVAV iteration in the time step - int const ZoneNode, // zone node number - int const EP_UNUSED(HCoilType), // type of hot water coil !unused1208 - Real64 const HWFlow, // hot water flow (kg/s) - Real64 const HCoilReq, // gas or elec coil demand requested - int const FanType, // type of fan - Real64 const AirFlow, // air flow rate (kg/s) - int const FanOn, // 1 means fan is on - Real64 &LoadMet // load met by unit (watts) + bool const FirstHVACIteration, // flag for 1st HVAV iteration in the time step + int const ZoneNode, // zone node number + [[maybe_unused]] int const HCoilType, // type of hot water coil !unused1208 + Real64 const HWFlow, // hot water flow (kg/s) + Real64 const HCoilReq, // gas or elec coil demand requested + int const FanType, // type of fan + Real64 const AirFlow, // air flow rate (kg/s) + int const FanOn, // 1 means fan is on + Real64 &LoadMet // load met by unit (watts) ) { diff --git a/src/EnergyPlus/SizingManager.cc b/src/EnergyPlus/SizingManager.cc index 97ed71d249c..aa784de2446 100644 --- a/src/EnergyPlus/SizingManager.cc +++ b/src/EnergyPlus/SizingManager.cc @@ -2156,11 +2156,11 @@ namespace SizingManager { int &NumAlphas, Array1D const &Numbers, int &NumNumbers, - Array1D_bool const &EP_UNUSED(lNumericBlanks), // Unused + [[maybe_unused]] Array1D_bool const &lNumericBlanks, // Unused Array1D_bool const &lAlphaBlanks, Array1D_string const &cAlphaFields, - Array1D_string const &EP_UNUSED(cNumericFields), // Unused - bool &ErrorsFound // If errors found in input + [[maybe_unused]] Array1D_string const &cNumericFields, // Unused + bool &ErrorsFound // If errors found in input ) { @@ -4802,8 +4802,8 @@ namespace SizingManager { } } - // Update the sizing for the entire facility to gather values for reporting - Glazer January 2017 - void UpdateFacilitySizing(EnergyPlusData &state, DataGlobalConstants::CallIndicator const CallIndicator) + // Update the sizing for the entire facilty to gather values for reporting - Glazer January 2017 + void UpdateFacilitySizing([[maybe_unused]] EnergyPlusData &state, DataGlobalConstants::CallIndicator const CallIndicator) { int NumOfTimeStepInDay = state.dataGlobal->NumOfTimeStepInHour * 24; diff --git a/src/EnergyPlus/SolarCollectors.cc b/src/EnergyPlus/SolarCollectors.cc index 005befefafc..0c2ac4fc565 100644 --- a/src/EnergyPlus/SolarCollectors.cc +++ b/src/EnergyPlus/SolarCollectors.cc @@ -735,10 +735,11 @@ namespace SolarCollectors { } } - void CollectorData::simulate(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation), - bool const EP_UNUSED(FirstHVACIteration), - Real64 &EP_UNUSED(CurLoad), - bool const EP_UNUSED(RunFlag)) + void CollectorData::simulate(EnergyPlusData &state, + [[maybe_unused]] const PlantLocation &calledFromLocation, + [[maybe_unused]] bool const FirstHVACIteration, + [[maybe_unused]] Real64 &CurLoad, + [[maybe_unused]] bool const RunFlag) { this->initialize(state); diff --git a/src/EnergyPlus/SolarCollectors.hh b/src/EnergyPlus/SolarCollectors.hh index ce8bf2c8451..2574f210211 100644 --- a/src/EnergyPlus/SolarCollectors.hh +++ b/src/EnergyPlus/SolarCollectors.hh @@ -230,7 +230,7 @@ namespace SolarCollectors { void initialize(EnergyPlusData &state); - void simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; + void simulate([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; void CalcTransRefAbsOfCover(EnergyPlusData &state, Real64 IncidentAngle, // Angle of incidence (radians) Real64 &TransSys, // cover system solar transmittance diff --git a/src/EnergyPlus/SplitterComponent.cc b/src/EnergyPlus/SplitterComponent.cc index f6acc9d5a77..dc76d991d86 100644 --- a/src/EnergyPlus/SplitterComponent.cc +++ b/src/EnergyPlus/SplitterComponent.cc @@ -531,7 +531,7 @@ namespace SplitterComponent { } // The FirstCall END IF } - void ReportSplitter(int const EP_UNUSED(SplitterNum)) + void ReportSplitter([[maybe_unused]] int const SplitterNum) { // SUBROUTINE INFORMATION: diff --git a/src/EnergyPlus/StandardRatings.cc b/src/EnergyPlus/StandardRatings.cc index e462ef513ec..4ee757c53e7 100644 --- a/src/EnergyPlus/StandardRatings.cc +++ b/src/EnergyPlus/StandardRatings.cc @@ -1646,7 +1646,7 @@ namespace StandardRatings { int const CapFFlowCurveIndex, // Index for the capacity as a function of flow fraction modifier curve int const EIRFTempCurveIndex, // Index for the EIR as a function of temperature modifier curve int const EIRFFlowCurveIndex, // Index for the EIR as a function of flow fraction modifier curve - int const EP_UNUSED(PLFFPLRCurveIndex), // Index for the EIR vs part-load ratio curve + [[maybe_unused]] int const PLFFPLRCurveIndex, // Index for the EIR vs part-load ratio curve Real64 const RatedTotalCapacity, // Rated gross total cooling capacity Real64 const RatedCOP, // Rated gross COP Real64 const RatedAirVolFlowRate, // air flow rate through the coil at rated condition @@ -1968,8 +1968,8 @@ namespace StandardRatings { void MultiSpeedDXHeatingCoilStandardRatings( EnergyPlusData &state, - std::string const &EP_UNUSED(DXCoilName), // Name of DX coil for which HSPF is calculated - std::string const &EP_UNUSED(DXCoilType), // Type of DX coil for which HSPF is calculated + [[maybe_unused]] std::string const &DXCoilName, // Name of DX coil for which HSPF is calculated + [[maybe_unused]] std::string const &DXCoilType, // Type of DX coil for which HSPF is calculated Array1A_int const CapFTempCurveIndex, // Index for the capacity as a function of temperature modifier curve Array1A_int const CapFFlowCurveIndex, // Index for the capacity as a function of flow fraction modifier curve Array1A_int const EIRFTempCurveIndex, // Index for the EIR as a function of temperature modifier curve diff --git a/src/EnergyPlus/SteamBaseboardRadiator.cc b/src/EnergyPlus/SteamBaseboardRadiator.cc index c8e2818ae3c..10ee1e17a2a 100644 --- a/src/EnergyPlus/SteamBaseboardRadiator.cc +++ b/src/EnergyPlus/SteamBaseboardRadiator.cc @@ -1410,13 +1410,14 @@ namespace SteamBaseboardRadiator { return SumHATsurf; } - void UpdateSteamBaseboardPlantConnection(EnergyPlusData &state, int const BaseboardTypeNum, // type index - std::string const &BaseboardName, // component name - int const EP_UNUSED(EquipFlowCtrl), // Flow control mode for the equipment - int const EP_UNUSED(LoopNum), // Plant loop index for where called from - int const EP_UNUSED(LoopSide), // Plant loop side index for where called from - int &CompIndex, // Chiller number pointer - bool const EP_UNUSED(FirstHVACIteration), + void UpdateSteamBaseboardPlantConnection(EnergyPlusData &state, + int const BaseboardTypeNum, // type index + std::string const &BaseboardName, // component name + [[maybe_unused]] int const EquipFlowCtrl, // Flow control mode for the equipment + [[maybe_unused]] int const LoopNum, // Plant loop index for where called from + [[maybe_unused]] int const LoopSide, // Plant loop side index for where called from + int &CompIndex, // Chiller number pointer + [[maybe_unused]] bool const FirstHVACIteration, bool &InitLoopEquip // If not zero, calculate the max load for operating conditions ) { diff --git a/src/EnergyPlus/SteamCoils.cc b/src/EnergyPlus/SteamCoils.cc index 6c644817656..a1d664d6db3 100644 --- a/src/EnergyPlus/SteamCoils.cc +++ b/src/EnergyPlus/SteamCoils.cc @@ -1521,7 +1521,8 @@ namespace SteamCoils { return IndexNum; } - void CheckSteamCoilSchedule(EnergyPlusData &state, std::string const &EP_UNUSED(CompType), std::string const &CompName, Real64 &Value, int &CompIndex) + void CheckSteamCoilSchedule( + EnergyPlusData &state, [[maybe_unused]] std::string const &CompType, std::string const &CompName, Real64 &Value, int &CompIndex) { // SUBROUTINE INFORMATION: @@ -1741,9 +1742,9 @@ namespace SteamCoils { } int GetCoilAirOutletNode(EnergyPlusData &state, - std::string const &CoilType, // must match coil types in this module - std::string const &CoilName, // must match coil names for the coil type - bool &EP_UNUSED(ErrorsFound) // set to true if problem + std::string const &CoilType, // must match coil types in this module + std::string const &CoilName, // must match coil names for the coil type + [[maybe_unused]] bool &ErrorsFound // set to true if problem ) { diff --git a/src/EnergyPlus/SteamCoils.hh b/src/EnergyPlus/SteamCoils.hh index aff757c7e78..f071b43f574 100644 --- a/src/EnergyPlus/SteamCoils.hh +++ b/src/EnergyPlus/SteamCoils.hh @@ -232,7 +232,7 @@ namespace SteamCoils { bool &ErrorsFound // set to true if problem ); - Real64 GetCoilCapacity(EnergyPlusData &EP_UNUSED(state), std::string const &CoilType, // must match coil types in this module + Real64 GetCoilCapacity([[maybe_unused]] EnergyPlusData &state, std::string const &CoilType, // must match coil types in this module std::string const &CoilName, // must match coil names for the coil type bool &ErrorsFound // set to true if problem ); diff --git a/src/EnergyPlus/SurfaceGroundHeatExchanger.cc b/src/EnergyPlus/SurfaceGroundHeatExchanger.cc index 2fab0710f1b..2b46aa4d922 100644 --- a/src/EnergyPlus/SurfaceGroundHeatExchanger.cc +++ b/src/EnergyPlus/SurfaceGroundHeatExchanger.cc @@ -133,7 +133,8 @@ namespace SurfaceGroundHeatExchanger { int const SurfCond_Ground(1); int const SurfCond_Exposed(2); - PlantComponent *SurfaceGroundHeatExchangerData::factory(EnergyPlusData &state, int const EP_UNUSED(objectType), std::string const objectName) + PlantComponent * + SurfaceGroundHeatExchangerData::factory(EnergyPlusData &state, [[maybe_unused]] int const objectType, std::string const objectName) { if (state.dataSurfaceGroundHeatExchangers->GetInputFlag) { GetSurfaceGroundHeatExchanger(state); @@ -151,10 +152,11 @@ namespace SurfaceGroundHeatExchanger { return nullptr; } - void SurfaceGroundHeatExchangerData::simulate(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation), + void SurfaceGroundHeatExchangerData::simulate(EnergyPlusData &state, + [[maybe_unused]] const PlantLocation &calledFromLocation, bool const FirstHVACIteration, - Real64 &EP_UNUSED(CurLoad), - bool const EP_UNUSED(RunFlag)) + [[maybe_unused]] Real64 &CurLoad, + [[maybe_unused]] bool const RunFlag) { this->InitSurfaceGroundHeatExchanger(state); this->CalcSurfaceGroundHeatExchanger(state, FirstHVACIteration); diff --git a/src/EnergyPlus/SurfaceGroundHeatExchanger.hh b/src/EnergyPlus/SurfaceGroundHeatExchanger.hh index da11bf744ff..da941bc1b00 100644 --- a/src/EnergyPlus/SurfaceGroundHeatExchanger.hh +++ b/src/EnergyPlus/SurfaceGroundHeatExchanger.hh @@ -173,7 +173,7 @@ namespace SurfaceGroundHeatExchanger { { } - void simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; + void simulate([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; static PlantComponent *factory(EnergyPlusData &state, int objectType, std::string objectName); diff --git a/src/EnergyPlus/SwimmingPool.cc b/src/EnergyPlus/SwimmingPool.cc index 2f1c139ec21..730d278f87f 100644 --- a/src/EnergyPlus/SwimmingPool.cc +++ b/src/EnergyPlus/SwimmingPool.cc @@ -134,10 +134,11 @@ namespace SwimmingPool { ReportSwimmingPool(state); } - void SwimmingPoolData::simulate(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation), + void SwimmingPoolData::simulate(EnergyPlusData &state, + [[maybe_unused]] const PlantLocation &calledFromLocation, bool FirstHVACIteration, - Real64 &EP_UNUSED(CurLoad), - bool EP_UNUSED(RunFlag)) + [[maybe_unused]] Real64 &CurLoad, + [[maybe_unused]] bool RunFlag) { this->initialize(state, FirstHVACIteration); diff --git a/src/EnergyPlus/SwimmingPool.hh b/src/EnergyPlus/SwimmingPool.hh index 78aaf32eb56..f7fd5af8437 100644 --- a/src/EnergyPlus/SwimmingPool.hh +++ b/src/EnergyPlus/SwimmingPool.hh @@ -160,7 +160,7 @@ namespace SwimmingPool { { } - void simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; + void simulate([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; void ErrorCheckSetupPoolSurface(EnergyPlusData &state, std::string const Alpha1, diff --git a/src/EnergyPlus/SystemAvailabilityManager.cc b/src/EnergyPlus/SystemAvailabilityManager.cc index b915e5a9365..c6b8b98a6f0 100644 --- a/src/EnergyPlus/SystemAvailabilityManager.cc +++ b/src/EnergyPlus/SystemAvailabilityManager.cc @@ -2276,11 +2276,11 @@ namespace SystemAvailabilityManager { } void CalcOptStartSysAvailMgr(EnergyPlusData &state, - int const SysAvailNum, // number of the current scheduled system availability manager - int const PriAirSysNum, // number of the primary air system affected by this Avail. Manager - int &AvailStatus, // System status indicator - Optional_int_const EP_UNUSED(ZoneEquipType), // Type of ZoneHVAC equipment component - Optional_int_const EP_UNUSED(CompNum) // Index of ZoneHVAC equipment component + int const SysAvailNum, // number of the current scheduled system availability manager + int const PriAirSysNum, // number of the primary air system affected by this Avail. Manager + int &AvailStatus, // System status indicator + [[maybe_unused]] Optional_int_const ZoneEquipType, // Type of ZoneHVAC equipment component + [[maybe_unused]] Optional_int_const CompNum // Index of ZoneHVAC equipment component ) { diff --git a/src/EnergyPlus/TARCOGOutput.cc b/src/EnergyPlus/TARCOGOutput.cc index 2a36b4f863f..163c5ab77f4 100644 --- a/src/EnergyPlus/TARCOGOutput.cc +++ b/src/EnergyPlus/TARCOGOutput.cc @@ -519,7 +519,7 @@ namespace TARCOGOutput { } void WriteModifiedArguments(InputOutputFile &InArgumentsFile, - std::string const &EP_UNUSED(DBGD), + [[maybe_unused]] std::string const &DBGD, Real64 const esky, Real64 const trmout, Real64 const trmin, @@ -633,7 +633,7 @@ namespace TARCOGOutput { } void WriteOutputArguments(InputOutputFile &OutArgumentsFile, - std::string const &EP_UNUSED(DBGD), + [[maybe_unused]] std::string const &DBGD, int const nlayer, Real64 const tamb, const Array1D &q, @@ -936,7 +936,7 @@ namespace TARCOGOutput { } void WriteOutputEN673(InputOutputFile &OutArgumentsFile, - std::string const &EP_UNUSED(DBGD), + [[maybe_unused]] std::string const &DBGD, int const nlayer, Real64 const ufactor, Real64 const hout, @@ -946,7 +946,7 @@ namespace TARCOGOutput { const Array1D &hg, const Array1D &hr, const Array1D &hs, - int &EP_UNUSED(nperr)) + [[maybe_unused]] int &nperr) { // Argument array dimensioning diff --git a/src/EnergyPlus/ThermalComfort.cc b/src/EnergyPlus/ThermalComfort.cc index 3c637b546a2..1bde4d6253f 100644 --- a/src/EnergyPlus/ThermalComfort.cc +++ b/src/EnergyPlus/ThermalComfort.cc @@ -1347,9 +1347,10 @@ namespace ThermalComfort { } } - void DERIV(EnergyPlusData &state, int &EP_UNUSED(TempIndiceNum), // Number of temperature indices unused1208 - Array1D &EP_UNUSED(Temp), // Temperature unused1208 - Array1D &TempChange // Change of temperature + void DERIV(EnergyPlusData &state, + [[maybe_unused]] int &TempIndiceNum, // Number of temperature indices unused1208 + [[maybe_unused]] Array1D &Temp, // Temperature unused1208 + Array1D &TempChange // Change of temperature ) { diff --git a/src/EnergyPlus/ThermalISO15099Calc.cc b/src/EnergyPlus/ThermalISO15099Calc.cc index 9678e0d9c3b..d63c07a5ece 100644 --- a/src/EnergyPlus/ThermalISO15099Calc.cc +++ b/src/EnergyPlus/ThermalISO15099Calc.cc @@ -2916,9 +2916,9 @@ namespace ThermalISO15099Calc { int const nlayer, const Array1D &gap, Array1D &hcgas, - Real64 const EP_UNUSED(VacuumMaxGapThickness), - int &EP_UNUSED(nperr), - std::string &EP_UNUSED(ErrorMessage)) + [[maybe_unused]] Real64 const VacuumMaxGapThickness, + [[maybe_unused]] int &nperr, + [[maybe_unused]] std::string &ErrorMessage) { //*********************************************************************** // subroutine to calculate effective conductance of support pillars diff --git a/src/EnergyPlus/UnitHeater.cc b/src/EnergyPlus/UnitHeater.cc index cff03d1ac2a..7abee8eec3a 100644 --- a/src/EnergyPlus/UnitHeater.cc +++ b/src/EnergyPlus/UnitHeater.cc @@ -658,9 +658,9 @@ namespace UnitHeater { } void InitUnitHeater(EnergyPlusData &state, - int const UnitHeatNum, // index for the current unit heater - int const ZoneNum, // number of zone being served - bool const EP_UNUSED(FirstHVACIteration) // TRUE if 1st HVAC simulation of system timestep + int const UnitHeatNum, // index for the current unit heater + int const ZoneNum, // number of zone being served + [[maybe_unused]] bool const FirstHVACIteration // TRUE if 1st HVAC simulation of system timestep ) { diff --git a/src/EnergyPlus/UnitarySystem.hh b/src/EnergyPlus/UnitarySystem.hh index d11857cb25b..3d96e7c77ba 100644 --- a/src/EnergyPlus/UnitarySystem.hh +++ b/src/EnergyPlus/UnitarySystem.hh @@ -82,7 +82,7 @@ namespace UnitarySystems { bool m_SingleModeFlag; static void getDesignSpecMSHP(EnergyPlusData &state); - static void getDesignSpecMSHPdata(EnergyPlusData &EP_UNUSED(state), bool errorsFound); + static void getDesignSpecMSHPdata([[maybe_unused]] EnergyPlusData &state, bool errorsFound); }; struct UnitarySys : HVACSystemData diff --git a/src/EnergyPlus/UserDefinedComponents.cc b/src/EnergyPlus/UserDefinedComponents.cc index 73b451142e2..275b62599f1 100644 --- a/src/EnergyPlus/UserDefinedComponents.cc +++ b/src/EnergyPlus/UserDefinedComponents.cc @@ -152,7 +152,8 @@ namespace UserDefinedComponents { } } - void UserPlantComponentStruct::getDesignCapacities(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) + void UserPlantComponentStruct::getDesignCapacities( + [[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) { int thisLoop = 0; for (int loop = 1; loop <= this->NumPlantConnections; ++loop) { @@ -166,10 +167,11 @@ namespace UserDefinedComponents { OptLoad = this->Loop(thisLoop).OptLoad; } - void UserPlantComponentStruct::UserPlantComponentStruct::simulate(EnergyPlusData &state, const EnergyPlus::PlantLocation &calledFromLocation, - bool EP_UNUSED(FirstHVACIteration), + void UserPlantComponentStruct::UserPlantComponentStruct::simulate(EnergyPlusData &state, + const EnergyPlus::PlantLocation &calledFromLocation, + [[maybe_unused]] bool FirstHVACIteration, Real64 &CurLoad, - bool EP_UNUSED(RunFlag)) + [[maybe_unused]] bool RunFlag) { // SUBROUTINE INFORMATION: // AUTHOR B. Griffith @@ -401,7 +403,11 @@ namespace UserDefinedComponents { } void SimAirTerminalUserDefined(EnergyPlusData &state, - std::string const &CompName, bool const EP_UNUSED(FirstHVACIteration), int const ZoneNum, int const EP_UNUSED(ZoneNodeNum), int &CompIndex) + std::string const &CompName, + [[maybe_unused]] bool const FirstHVACIteration, + int const ZoneNum, + [[maybe_unused]] int const ZoneNodeNum, + int &CompIndex) { // SUBROUTINE INFORMATION: diff --git a/src/EnergyPlus/UserDefinedComponents.hh b/src/EnergyPlus/UserDefinedComponents.hh index 9204185c308..1cf79f8e11c 100644 --- a/src/EnergyPlus/UserDefinedComponents.hh +++ b/src/EnergyPlus/UserDefinedComponents.hh @@ -188,7 +188,7 @@ namespace UserDefinedComponents { static PlantComponent *factory(EnergyPlusData &state, std::string const &objectName); - void onInitLoopEquip(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation) override; + void onInitLoopEquip([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation) override; void getDesignCapacities(EnergyPlusData &state, const PlantLocation &calledFromLocation, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) override; diff --git a/src/EnergyPlus/UtilityRoutines.cc b/src/EnergyPlus/UtilityRoutines.cc index e7c9870eb2a..5c06c5a1fda 100644 --- a/src/EnergyPlus/UtilityRoutines.cc +++ b/src/EnergyPlus/UtilityRoutines.cc @@ -461,7 +461,7 @@ namespace UtilityRoutines { } } - bool ValidateFuelType(EnergyPlusData &EP_UNUSED(state), + bool ValidateFuelType([[maybe_unused]] EnergyPlusData &state, std::string const &FuelTypeInput, std::string &FuelTypeOutput, bool &FuelTypeErrorsFound, diff --git a/src/EnergyPlus/VariableSpeedCoils.cc b/src/EnergyPlus/VariableSpeedCoils.cc index 45d0377e17e..2e53176a058 100644 --- a/src/EnergyPlus/VariableSpeedCoils.cc +++ b/src/EnergyPlus/VariableSpeedCoils.cc @@ -3006,16 +3006,16 @@ namespace VariableSpeedCoils { //****************************************************************************** void InitVarSpeedCoil(EnergyPlusData &state, - int const DXCoilNum, // Current DXCoilNum under simulation - Real64 const MaxONOFFCyclesperHour, // Maximum cycling rate of heat pump [cycles/hr] - Real64 const HPTimeConstant, // Heat pump time constant [s] - Real64 const FanDelayTime, // Fan delay time, time delay for the HP's fan to - Real64 const SensLoad, // Control zone sensible load[W] - Real64 const LatentLoad, // Control zone latent load[W] - int const CyclingScheme, // fan operating mode - Real64 const EP_UNUSED(OnOffAirFlowRatio), // ratio of compressor on flow to average flow over time step - Real64 const SpeedRatio, // compressor speed ratio - int const SpeedNum // compressor speed number + int const DXCoilNum, // Current DXCoilNum under simulation + Real64 const MaxONOFFCyclesperHour, // Maximum cycling rate of heat pump [cycles/hr] + Real64 const HPTimeConstant, // Heat pump time constant [s] + Real64 const FanDelayTime, // Fan delay time, time delay for the HP's fan to + Real64 const SensLoad, // Control zone sensible load[W] + Real64 const LatentLoad, // Control zone latent load[W] + int const CyclingScheme, // fan operating mode + [[maybe_unused]] Real64 const OnOffAirFlowRatio, // ratio of compressor on flow to average flow over time step + Real64 const SpeedRatio, // compressor speed ratio + int const SpeedNum // compressor speed number ) { @@ -4855,16 +4855,16 @@ namespace VariableSpeedCoils { } void CalcVarSpeedCoilCooling(EnergyPlusData &state, - int const DXCoilNum, // Heat Pump Number - int const CyclingScheme, // Fan/Compressor cycling scheme indicator - Real64 &RuntimeFrac, // Runtime Fraction of compressor or percent on time (on-time/cycle time) - Real64 const EP_UNUSED(SensDemand), // Cooling Sensible Demand [W] !unused1208 - Real64 const EP_UNUSED(LatentDemand), // Cooling Latent Demand [W] - int const CompOp, // compressor operation flag - Real64 const PartLoadRatio, // compressor part load ratio - Real64 const EP_UNUSED(OnOffAirFlowRatio), // ratio of compressor on flow to average flow over time step - Real64 const SpeedRatio, // SpeedRatio varies between 1.0 (higher speed) and 0.0 (lower speed) - int const SpeedNum // Speed number, high bound + int const DXCoilNum, // Heat Pump Number + int const CyclingScheme, // Fan/Compressor cycling scheme indicator + Real64 &RuntimeFrac, // Runtime Fraction of compressor or percent on time (on-time/cycle time) + [[maybe_unused]] Real64 const SensDemand, // Cooling Sensible Demand [W] !unused1208 + [[maybe_unused]] Real64 const LatentDemand, // Cooling Latent Demand [W] + int const CompOp, // compressor operation flag + Real64 const PartLoadRatio, // compressor part load ratio + [[maybe_unused]] Real64 const OnOffAirFlowRatio, // ratio of compressor on flow to average flow over time step + Real64 const SpeedRatio, // SpeedRatio varies between 1.0 (higher speed) and 0.0 (lower speed) + int const SpeedNum // Speed number, high bound ) { @@ -6075,15 +6075,15 @@ namespace VariableSpeedCoils { } void CalcVarSpeedCoilHeating(EnergyPlusData &state, - int const DXCoilNum, // Heat Pump Number - int const CyclingScheme, // Fan/Compressor cycling scheme indicator - Real64 &RuntimeFrac, // Runtime Fraction of compressor or percent on time (on-time/cycle time) - Real64 const EP_UNUSED(SensDemand), // Cooling Sensible Demand [W] !unused1208 - int const CompOp, // compressor operation flag - Real64 const PartLoadRatio, // compressor part load ratio - Real64 const EP_UNUSED(OnOffAirFlowRatio), // ratio of compressor on flow to average flow over time step - Real64 const SpeedRatio, // SpeedRatio varies between 1.0 (higher speed) and 0.0 (lower speed) - int const SpeedNum // Speed number, high bound, i.e. SpeedNum - 1 is the other side + int const DXCoilNum, // Heat Pump Number + int const CyclingScheme, // Fan/Compressor cycling scheme indicator + Real64 &RuntimeFrac, // Runtime Fraction of compressor or percent on time (on-time/cycle time) + [[maybe_unused]] Real64 const SensDemand, // Cooling Sensible Demand [W] !unused1208 + int const CompOp, // compressor operation flag + Real64 const PartLoadRatio, // compressor part load ratio + [[maybe_unused]] Real64 const OnOffAirFlowRatio, // ratio of compressor on flow to average flow over time step + Real64 const SpeedRatio, // SpeedRatio varies between 1.0 (higher speed) and 0.0 (lower speed) + int const SpeedNum // Speed number, high bound, i.e. SpeedNum - 1 is the other side ) { diff --git a/src/EnergyPlus/Vectors.cc b/src/EnergyPlus/Vectors.cc index 8020796f172..ff115075f06 100644 --- a/src/EnergyPlus/Vectors.cc +++ b/src/EnergyPlus/Vectors.cc @@ -293,14 +293,14 @@ namespace Vectors { vec.z = nint64(vec.z * roundto) / roundto; } - void DetermineAzimuthAndTilt(Array1D const &Surf, // Surface Definition - int const EP_UNUSED(NSides), // Number of sides to surface - Real64 &Azimuth, // Outward Normal Azimuth Angle - Real64 &Tilt, // Tilt angle of surface + void DetermineAzimuthAndTilt(Array1D const &Surf, // Surface Definition + [[maybe_unused]] int const NSides, // Number of sides to surface + Real64 &Azimuth, // Outward Normal Azimuth Angle + Real64 &Tilt, // Tilt angle of surface Vector &lcsx, Vector &lcsy, Vector &lcsz, - Real64 const EP_UNUSED(surfaceArea), + [[maybe_unused]] Real64 const surfaceArea, Vector const &NewellSurfaceNormalVector) { diff --git a/src/EnergyPlus/VentilatedSlab.cc b/src/EnergyPlus/VentilatedSlab.cc index 1cbdff2c1ce..712ebcc3e92 100644 --- a/src/EnergyPlus/VentilatedSlab.cc +++ b/src/EnergyPlus/VentilatedSlab.cc @@ -3380,8 +3380,8 @@ namespace VentilatedSlab { } void CalcVentilatedSlabRadComps(EnergyPlusData &state, - int const Item, // System index in ventilated slab array - bool const EP_UNUSED(FirstHVACIteration) // flag for 1st HVAV iteration in the time step !unused1208 + int const Item, // System index in ventilated slab array + [[maybe_unused]] bool const FirstHVACIteration // flag for 1st HVAV iteration in the time step !unused1208 ) { @@ -4142,8 +4142,9 @@ namespace VentilatedSlab { Node(OAMixOutNode).Press = Node(InletNode).Press; } - void UpdateVentilatedSlab(EnergyPlusData &state, int const Item, // Index for the ventilated slab under consideration within the derived types - bool const EP_UNUSED(FirstHVACIteration) // TRUE if 1st HVAC simulation of system timestep !unused1208 + void UpdateVentilatedSlab(EnergyPlusData &state, + int const Item, // Index for the ventilated slab under consideration within the derived types + [[maybe_unused]] bool const FirstHVACIteration // TRUE if 1st HVAC simulation of system timestep !unused1208 ) { diff --git a/src/EnergyPlus/WaterCoils.cc b/src/EnergyPlus/WaterCoils.cc index 0acb3a6a45a..ff189a9294d 100644 --- a/src/EnergyPlus/WaterCoils.cc +++ b/src/EnergyPlus/WaterCoils.cc @@ -5596,7 +5596,8 @@ namespace WaterCoils { } } - void CheckWaterCoilSchedule(EnergyPlusData &state, std::string const &EP_UNUSED(CompType), // unused1208 + void CheckWaterCoilSchedule(EnergyPlusData &state, + [[maybe_unused]] std::string const &CompType, // unused1208 std::string const &CompName, Real64 &Value, int &CompIndex) @@ -6459,13 +6460,14 @@ namespace WaterCoils { return Capacity; } - void UpdateWaterToAirCoilPlantConnection(EnergyPlusData &state, int const CoilTypeNum, + void UpdateWaterToAirCoilPlantConnection(EnergyPlusData &state, + int const CoilTypeNum, std::string const &CoilName, - int const EP_UNUSED(EquipFlowCtrl), // Flow control mode for the equipment - int const LoopNum, // Plant loop index for where called from - int const LoopSide, // Plant loop side index for where called from - int &CompIndex, // Chiller number pointer - bool const EP_UNUSED(FirstHVACIteration), + [[maybe_unused]] int const EquipFlowCtrl, // Flow control mode for the equipment + int const LoopNum, // Plant loop index for where called from + int const LoopSide, // Plant loop side index for where called from + int &CompIndex, // Chiller number pointer + [[maybe_unused]] bool const FirstHVACIteration, bool &InitLoopEquip // If not zero, calculate the max load for operating conditions ) { diff --git a/src/EnergyPlus/WaterThermalTanks.cc b/src/EnergyPlus/WaterThermalTanks.cc index 706ae12eff5..0f2eae65950 100644 --- a/src/EnergyPlus/WaterThermalTanks.cc +++ b/src/EnergyPlus/WaterThermalTanks.cc @@ -188,8 +188,11 @@ namespace WaterThermalTanks { } } - void - WaterThermalTankData::getDesignCapacities(EnergyPlusData &EP_UNUSED(state), const PlantLocation &EP_UNUSED(calledFromLocation), Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) + void WaterThermalTankData::getDesignCapacities([[maybe_unused]] EnergyPlusData &state, + [[maybe_unused]] const PlantLocation &calledFromLocation, + Real64 &MaxLoad, + Real64 &MinLoad, + Real64 &OptLoad) { MinLoad = 0.0; MaxLoad = this->MaxCapacity; @@ -263,7 +266,7 @@ namespace WaterThermalTanks { } void WaterThermalTankData::simulate( - EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool EP_UNUSED(RunFlag)) + EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, [[maybe_unused]] bool RunFlag) { // SUBROUTINE INFORMATION: // AUTHOR Brandon Anderson @@ -336,8 +339,8 @@ namespace WaterThermalTanks { Tank.onInitLoopEquip(state, calledFromLocation); } - void HeatPumpWaterHeaterData::getDesignCapacities(EnergyPlusData &EP_UNUSED(state), - const PlantLocation &EP_UNUSED(calledFromLocation), + void HeatPumpWaterHeaterData::getDesignCapacities([[maybe_unused]] EnergyPlusData &state, + [[maybe_unused]] const PlantLocation &calledFromLocation, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) @@ -348,7 +351,7 @@ namespace WaterThermalTanks { } void HeatPumpWaterHeaterData::simulate( - EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool EP_UNUSED(RunFlag)) + EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, [[maybe_unused]] bool RunFlag) { // SUBROUTINE INFORMATION: // AUTHOR Brandon Anderson @@ -9862,11 +9865,12 @@ namespace WaterThermalTanks { return NeedsHeatOrCool; } - Real64 WaterThermalTankData::PlantMassFlowRatesFunc(EnergyPlusData &state, int const InNodeNum, + Real64 WaterThermalTankData::PlantMassFlowRatesFunc(EnergyPlusData &state, + int const InNodeNum, bool const FirstHVACIteration, SideEnum const WaterThermalTankSide, int const PlantLoopSide, - bool const EP_UNUSED(PlumbedInSeries), + [[maybe_unused]] bool const PlumbedInSeries, int const BranchControlType, Real64 const OutletTemp, Real64 const DeadBandTemp, diff --git a/src/EnergyPlus/WaterThermalTanks.hh b/src/EnergyPlus/WaterThermalTanks.hh index 6ea6b88d450..ec174865b26 100644 --- a/src/EnergyPlus/WaterThermalTanks.hh +++ b/src/EnergyPlus/WaterThermalTanks.hh @@ -387,9 +387,9 @@ namespace WaterThermalTanks { void simulate(EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; - void onInitLoopEquip(EnergyPlusData &EP_UNUSED(state), const PlantLocation &EP_UNUSED(calledFromLocation)) override; + void onInitLoopEquip([[maybe_unused]] EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation) override; - void getDesignCapacities(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation), Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) override; + void getDesignCapacities(EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) override; }; struct WaterThermalTankData : PlantComponent @@ -773,9 +773,9 @@ namespace WaterThermalTanks { static void ValidatePLFCurve(EnergyPlusData &state, int CurveIndex, bool &IsValid); - void onInitLoopEquip(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation)) override; + void onInitLoopEquip(EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation) override; - void getDesignCapacities(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation), Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) override; + void getDesignCapacities(EnergyPlusData &state, [[maybe_unused]] const PlantLocation &calledFromLocation, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad) override; }; struct WaterHeaterDesuperheaterData diff --git a/src/EnergyPlus/WaterToAirHeatPump.cc b/src/EnergyPlus/WaterToAirHeatPump.cc index 4ec86900062..799d629be23 100644 --- a/src/EnergyPlus/WaterToAirHeatPump.cc +++ b/src/EnergyPlus/WaterToAirHeatPump.cc @@ -1028,11 +1028,12 @@ namespace WaterToAirHeatPump { state.dataWaterToAirHeatPump->WatertoAirHP(HPNum).OutletWaterEnthalpy = 0.0; } - void CalcWatertoAirHPCooling(EnergyPlusData &state, int const HPNum, // heat pump number + void CalcWatertoAirHPCooling(EnergyPlusData &state, + int const HPNum, // heat pump number int const CyclingScheme, // fan/compressor cycling scheme indicator bool const FirstHVACIteration, // first iteration flag Real64 const RuntimeFrac, - bool const EP_UNUSED(InitFlag), // suppress property errors if true + [[maybe_unused]] bool const InitFlag, // suppress property errors if true Real64 const SensDemand, int const CompOp, Real64 const PartLoadRatio) @@ -1694,11 +1695,12 @@ namespace WaterToAirHeatPump { return Residuum; } - void CalcWatertoAirHPHeating(EnergyPlusData &state, int const HPNum, // heat pump number + void CalcWatertoAirHPHeating(EnergyPlusData &state, + int const HPNum, // heat pump number int const CyclingScheme, // fan/compressor cycling scheme indicator bool const FirstHVACIteration, // first iteration flag Real64 const RuntimeFrac, - bool const EP_UNUSED(InitFlag), // first iteration flag + [[maybe_unused]] bool const InitFlag, // first iteration flag Real64 const SensDemand, int const CompOp, Real64 const PartLoadRatio) diff --git a/src/EnergyPlus/WaterToAirHeatPumpSimple.cc b/src/EnergyPlus/WaterToAirHeatPumpSimple.cc index 62fff3571ca..14cfcac741d 100644 --- a/src/EnergyPlus/WaterToAirHeatPumpSimple.cc +++ b/src/EnergyPlus/WaterToAirHeatPumpSimple.cc @@ -754,15 +754,15 @@ namespace WaterToAirHeatPumpSimple { //****************************************************************************** void InitSimpleWatertoAirHP(EnergyPlusData &state, - int const HPNum, // Current HPNum under simulation - Real64 const MaxONOFFCyclesperHour, // Maximum cycling rate of heat pump [cycles/hr] - Real64 const HPTimeConstant, // Heat pump time constant [s] - Real64 const FanDelayTime, // Fan delay time, time delay for the HP's fan to - Real64 const SensLoad, // Control zone sensible load[W] - Real64 const LatentLoad, // Control zone latent load[W] - int const EP_UNUSED(CyclingScheme), // fan operating mode - Real64 const EP_UNUSED(OnOffAirFlowRatio), // ratio of compressor on flow to average flow over time step - bool const FirstHVACIteration // Iteration flag + int const HPNum, // Current HPNum under simulation + Real64 const MaxONOFFCyclesperHour, // Maximum cycling rate of heat pump [cycles/hr] + Real64 const HPTimeConstant, // Heat pump time constant [s] + Real64 const FanDelayTime, // Fan delay time, time delay for the HP's fan to + Real64 const SensLoad, // Control zone sensible load[W] + Real64 const LatentLoad, // Control zone latent load[W] + [[maybe_unused]] int const CyclingScheme, // fan operating mode + [[maybe_unused]] Real64 const OnOffAirFlowRatio, // ratio of compressor on flow to average flow over time step + bool const FirstHVACIteration // Iteration flag ) { @@ -2034,14 +2034,15 @@ namespace WaterToAirHeatPumpSimple { } } - void CalcHPCoolingSimple(EnergyPlusData &state, int const HPNum, // Heat Pump Number - int const CyclingScheme, // Fan/Compressor cycling scheme indicator - Real64 const RuntimeFrac, // Runtime Fraction of compressor or percent on time (on-time/cycle time) - Real64 const EP_UNUSED(SensDemand), // Cooling Sensible Demand [W] !unused1208 - Real64 const EP_UNUSED(LatentDemand), // Cooling Latent Demand [W] - int const CompOp, // compressor operation flag - Real64 const PartLoadRatio, // compressor part load ratio - Real64 const EP_UNUSED(OnOffAirFlowRatio) // ratio of compressor on flow to average flow over time step + void CalcHPCoolingSimple(EnergyPlusData &state, + int const HPNum, // Heat Pump Number + int const CyclingScheme, // Fan/Compressor cycling scheme indicator + Real64 const RuntimeFrac, // Runtime Fraction of compressor or percent on time (on-time/cycle time) + [[maybe_unused]] Real64 const SensDemand, // Cooling Sensible Demand [W] !unused1208 + [[maybe_unused]] Real64 const LatentDemand, // Cooling Latent Demand [W] + int const CompOp, // compressor operation flag + Real64 const PartLoadRatio, // compressor part load ratio + [[maybe_unused]] Real64 const OnOffAirFlowRatio // ratio of compressor on flow to average flow over time step ) { @@ -2395,13 +2396,14 @@ namespace WaterToAirHeatPumpSimple { } } - void CalcHPHeatingSimple(EnergyPlusData &state, int const HPNum, // Heat Pump Number - int const CyclingScheme, // Fan/Compressor cycling scheme indicator - Real64 const RuntimeFrac, // Runtime Fraction of compressor - Real64 const EP_UNUSED(SensDemand), // Cooling Sensible Demand [W] !unused1208 - int const CompOp, // compressor operation flag - Real64 const PartLoadRatio, // compressor part load ratio - Real64 const EP_UNUSED(OnOffAirFlowRatio) // ratio of compressor on flow to average flow over time step + void CalcHPHeatingSimple(EnergyPlusData &state, + int const HPNum, // Heat Pump Number + int const CyclingScheme, // Fan/Compressor cycling scheme indicator + Real64 const RuntimeFrac, // Runtime Fraction of compressor + [[maybe_unused]] Real64 const SensDemand, // Cooling Sensible Demand [W] !unused1208 + int const CompOp, // compressor operation flag + Real64 const PartLoadRatio, // compressor part load ratio + [[maybe_unused]] Real64 const OnOffAirFlowRatio // ratio of compressor on flow to average flow over time step ) { diff --git a/src/EnergyPlus/WaterUse.cc b/src/EnergyPlus/WaterUse.cc index 3091b0d8d9f..6097c877ddd 100644 --- a/src/EnergyPlus/WaterUse.cc +++ b/src/EnergyPlus/WaterUse.cc @@ -203,10 +203,11 @@ namespace WaterUse { return nullptr; // LCOV_EXCL_LINE } - void WaterConnectionsType::simulate(EnergyPlusData &state, const PlantLocation &EP_UNUSED(calledFromLocation), + void WaterConnectionsType::simulate(EnergyPlusData &state, + [[maybe_unused]] const PlantLocation &calledFromLocation, bool FirstHVACIteration, - Real64 &EP_UNUSED(CurLoad), - bool EP_UNUSED(RunFlag)) + [[maybe_unused]] Real64 &CurLoad, + [[maybe_unused]] bool RunFlag) { // SUBROUTINE INFORMATION: diff --git a/src/EnergyPlus/WaterUse.hh b/src/EnergyPlus/WaterUse.hh index c89a38b3d9e..7274ac0535c 100644 --- a/src/EnergyPlus/WaterUse.hh +++ b/src/EnergyPlus/WaterUse.hh @@ -227,7 +227,7 @@ namespace WaterUse { static PlantComponent *factory(EnergyPlusData &state, std::string const &objectName); - void simulate(EnergyPlusData &EP_UNUSED(state), const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; + void simulate([[maybe_unused]] EnergyPlusData &state, const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag) override; void InitConnections(EnergyPlusData &state); @@ -241,7 +241,7 @@ namespace WaterUse { void ReportWaterUse(EnergyPlusData &state); - void setupOutputVars(EnergyPlusData &EP_UNUSED(state)); + void setupOutputVars([[maybe_unused]] EnergyPlusData &state); }; void SimulateWaterUse(EnergyPlusData &state, bool FirstHVACIteration); diff --git a/src/EnergyPlus/WeatherManager.cc b/src/EnergyPlus/WeatherManager.cc index 06bde7f82ea..8a7e510dfdf 100644 --- a/src/EnergyPlus/WeatherManager.cc +++ b/src/EnergyPlus/WeatherManager.cc @@ -3894,7 +3894,8 @@ namespace WeatherManager { //------------------------------------------------------------------------------ - void ASHRAETauModel(EnergyPlusData &EP_UNUSED(state), DesignDaySolarModel const TauModelType, // ASHRAETau solar model type ASHRAE_Tau or ASHRAE_Tau2017 + void ASHRAETauModel([[maybe_unused]] EnergyPlusData &state, + DesignDaySolarModel const TauModelType, // ASHRAETau solar model type ASHRAE_Tau or ASHRAE_Tau2017 Real64 const ETR, // extraterrestrial normal irradiance, W/m2 Real64 const CosZen, // COS( solar zenith angle), 0 - 1 Real64 const TauB, // beam tau factor diff --git a/src/EnergyPlus/WeatherManager.hh b/src/EnergyPlus/WeatherManager.hh index 18f57157b21..f170cacaca0 100644 --- a/src/EnergyPlus/WeatherManager.hh +++ b/src/EnergyPlus/WeatherManager.hh @@ -622,7 +622,7 @@ namespace WeatherManager { // Calculate sky temperature from weather data Real64 CalcSkyEmissivity(EnergyPlusData &state, EmissivityCalcType ESkyCalcType, Real64 OSky, Real64 DryBulb, Real64 DewPoint, Real64 RelHum); - void ASHRAETauModel(EnergyPlusData &EP_UNUSED(state), DesignDaySolarModel TauModelType, // ASHRAETau solar model type ASHRAE_Tau or ASHRAE_Tau2017 + void ASHRAETauModel([[maybe_unused]] EnergyPlusData &state, DesignDaySolarModel TauModelType, // ASHRAETau solar model type ASHRAE_Tau or ASHRAE_Tau2017 Real64 ETR, // extraterrestrial normal irradiance, W/m2 Real64 CosZen, // COS( solar zenith angle), 0 - 1 Real64 TauB, // beam tau factor diff --git a/src/EnergyPlus/WindTurbine.cc b/src/EnergyPlus/WindTurbine.cc index fecdba9bb58..92be57cf103 100644 --- a/src/EnergyPlus/WindTurbine.cc +++ b/src/EnergyPlus/WindTurbine.cc @@ -95,11 +95,11 @@ namespace WindTurbine { static std::string const BlankString; void SimWindTurbine(EnergyPlusData &state, - GeneratorType const EP_UNUSED(GeneratorType), // Type of Generator - std::string const &GeneratorName, // User specified name of Generator - int &GeneratorIndex, // Generator index - bool const RunFlag, // ON or OFF - Real64 const EP_UNUSED(WTLoad) // Electrical load on WT (not used) + [[maybe_unused]] GeneratorType const GeneratorType, // Type of Generator + std::string const &GeneratorName, // User specified name of Generator + int &GeneratorIndex, // Generator index + bool const RunFlag, // ON or OFF + [[maybe_unused]] Real64 const WTLoad // Electrical load on WT (not used) ) { @@ -151,10 +151,10 @@ namespace WindTurbine { } void GetWTGeneratorResults(EnergyPlusData &state, - GeneratorType const EP_UNUSED(GeneratorType), // Type of Generator - int const GeneratorIndex, // Generator number - Real64 &GeneratorPower, // Electrical power - Real64 &GeneratorEnergy, // Electrical energy + [[maybe_unused]] GeneratorType const GeneratorType, // Type of Generator + int const GeneratorIndex, // Generator number + Real64 &GeneratorPower, // Electrical power + Real64 &GeneratorEnergy, // Electrical energy Real64 &ThermalPower, Real64 &ThermalEnergy) { @@ -724,8 +724,8 @@ namespace WindTurbine { } void CalcWindTurbine(EnergyPlusData &state, - int const WindTurbineNum, // System is on - bool const EP_UNUSED(RunFlag) // System is on + int const WindTurbineNum, // System is on + [[maybe_unused]] bool const RunFlag // System is on ) { diff --git a/src/EnergyPlus/WindowAC.cc b/src/EnergyPlus/WindowAC.cc index 580f76797f4..f8289481483 100644 --- a/src/EnergyPlus/WindowAC.cc +++ b/src/EnergyPlus/WindowAC.cc @@ -1105,12 +1105,12 @@ namespace WindowAC { } void SimCyclingWindowAC(EnergyPlusData &state, - int const WindACNum, // number of the current window AC unit being simulated - int const EP_UNUSED(ZoneNum), // number of zone being served !unused1208 - bool const FirstHVACIteration, // TRUE if 1st HVAC simulation of system timestep - Real64 &PowerMet, // Sensible power supplied (W) - Real64 const QZnReq, // Sensible load to be met (W) - Real64 &LatOutputProvided // Latent power supplied (kg/s), negative = dehumidification + int const WindACNum, // number of the current window AC unit being simulated + [[maybe_unused]] int const ZoneNum, // number of zone being served !unused1208 + bool const FirstHVACIteration, // TRUE if 1st HVAC simulation of system timestep + Real64 &PowerMet, // Sensible power supplied (W) + Real64 const QZnReq, // Sensible load to be met (W) + Real64 &LatOutputProvided // Latent power supplied (kg/s), negative = dehumidification ) { diff --git a/src/EnergyPlus/WindowComplexManager.cc b/src/EnergyPlus/WindowComplexManager.cc index 91b59eae87b..121049199a0 100644 --- a/src/EnergyPlus/WindowComplexManager.cc +++ b/src/EnergyPlus/WindowComplexManager.cc @@ -1219,12 +1219,12 @@ namespace WindowComplexManager { } void SetupComplexWindowStateGeometry(EnergyPlusData &state, - int const ISurf, // Surface number of the complex fenestration - int const IState, // State number of the complex fenestration state - int const IConst, // Pointer to construction for this state - BSDFWindowGeomDescr &Window, // Window Geometry - BSDFGeomDescr &Geom, // State Geometry - BSDFStateDescr &EP_UNUSED(State) // State Description + int const ISurf, // Surface number of the complex fenestration + int const IState, // State number of the complex fenestration state + int const IConst, // Pointer to construction for this state + BSDFWindowGeomDescr &Window, // Window Geometry + BSDFGeomDescr &Geom, // State Geometry + [[maybe_unused]] BSDFStateDescr &State // State Description ) { @@ -1993,7 +1993,7 @@ namespace WindowComplexManager { } // Outgoing ray loop } - Real64 SkyWeight(Vector const &EP_UNUSED(DirVec)) // Direction of the element to be weighted + Real64 SkyWeight([[maybe_unused]] Vector const &DirVec) // Direction of the element to be weighted { // FUNCTION INFORMATION: @@ -2022,7 +2022,7 @@ namespace WindowComplexManager { return Wt; } - Real64 SkyGndWeight(Vector const &EP_UNUSED(PosVec)) // x,y,z(=0) of ground intersection pt + Real64 SkyGndWeight([[maybe_unused]] Vector const &PosVec) // x,y,z(=0) of ground intersection pt { // FUNCTION INFORMATION: @@ -2180,13 +2180,13 @@ namespace WindowComplexManager { } int FindInBasis(EnergyPlusData &state, - Vector const &RayToFind, // Ray vector direction in world CS - int const RadType, // Type of radiation: Front_Incident, etc. - int const ISurf, // Window Surface number - int const EP_UNUSED(IState), // Complex Fenestration state number - BasisStruct const &Basis, // Complex Fenestration basis root - Real64 &Theta, // Theta value for ray - Real64 &Phi // Phi value for ray + Vector const &RayToFind, // Ray vector direction in world CS + int const RadType, // Type of radiation: Front_Incident, etc. + int const ISurf, // Window Surface number + [[maybe_unused]] int const IState, // Complex Fenestration state number + BasisStruct const &Basis, // Complex Fenestration basis root + Real64 &Theta, // Theta value for ray + Real64 &Phi // Phi value for ray ) { diff --git a/src/EnergyPlus/WindowEquivalentLayer.cc b/src/EnergyPlus/WindowEquivalentLayer.cc index 10f6734b04d..d7649421768 100644 --- a/src/EnergyPlus/WindowEquivalentLayer.cc +++ b/src/EnergyPlus/WindowEquivalentLayer.cc @@ -1107,9 +1107,9 @@ namespace WindowEquivalentLayer { } Real64 RB_F(EnergyPlusData &state, - Real64 const THETA, // incidence angle, radians - int const EP_UNUSED(OPT), // options (unused) - const Array1D &P // parameters + Real64 const THETA, // incidence angle, radians + [[maybe_unused]] int const OPT, // options (unused) + const Array1D &P // parameters ) { // AUTHOR ASHRAE 1311-RP @@ -1978,16 +1978,16 @@ namespace WindowEquivalentLayer { } } - void PD_BEAM_CASE_I(Real64 const S, // pleat spacing (> 0) - Real64 const W, // pleat depth (>=0, same units as S) - Real64 const EP_UNUSED(OMEGA_H), // horizontal profile angle, radians - Real64 const DE, // width of illumination on pleat bottom (same units as S) + void PD_BEAM_CASE_I(Real64 const S, // pleat spacing (> 0) + Real64 const W, // pleat depth (>=0, same units as S) + [[maybe_unused]] Real64 const OMEGA_H, // horizontal profile angle, radians + Real64 const DE, // width of illumination on pleat bottom (same units as S) Real64 const RHOFF_BT_PARL, Real64 const TAUFF_BB_PARL, Real64 const TAUFF_BD_PARL, - Real64 const EP_UNUSED(RHOBF_BT_PARL), - Real64 const EP_UNUSED(TAUBF_BB_PARL), - Real64 const EP_UNUSED(TAUBF_BD_PARL), + [[maybe_unused]] Real64 const RHOBF_BT_PARL, + [[maybe_unused]] Real64 const TAUBF_BB_PARL, + [[maybe_unused]] Real64 const TAUBF_BD_PARL, Real64 const RHOFF_BT_PERP, Real64 const TAUFF_BB_PERP, Real64 const TAUFF_BD_PERP, @@ -2404,16 +2404,16 @@ namespace WindowEquivalentLayer { RHO_BD = (RHOFF_BT_PARL + TAUBF_DD * G1 + G8) / 2.0; } - void PD_BEAM_CASE_II(Real64 const S, // pleat spacing (> 0) - Real64 const W, // pleat depth (>=0, same units as S) - Real64 const EP_UNUSED(OMEGA_H), // horizontal profile angle, radians - Real64 const DE, // width of illumination on pleat bottom (same units as S) + void PD_BEAM_CASE_II(Real64 const S, // pleat spacing (> 0) + Real64 const W, // pleat depth (>=0, same units as S) + [[maybe_unused]] Real64 const OMEGA_H, // horizontal profile angle, radians + Real64 const DE, // width of illumination on pleat bottom (same units as S) Real64 const RHOFF_BT_PARL, Real64 const TAUFF_BB_PARL, Real64 const TAUFF_BD_PARL, - Real64 const EP_UNUSED(RHOBF_BT_PARL), - Real64 const EP_UNUSED(TAUBF_BB_PARL), - Real64 const EP_UNUSED(TAUBF_BD_PARL), + [[maybe_unused]] Real64 const RHOBF_BT_PARL, + [[maybe_unused]] Real64 const TAUBF_BB_PARL, + [[maybe_unused]] Real64 const TAUBF_BD_PARL, Real64 const RHOFF_BT_PERP, Real64 const TAUFF_BB_PERP, Real64 const TAUFF_BD_PERP, @@ -2743,9 +2743,9 @@ namespace WindowEquivalentLayer { Real64 const RHOFF_BT_PARL, Real64 const TAUFF_BB_PARL, Real64 const TAUFF_BD_PARL, - Real64 const EP_UNUSED(RHOBF_BT_PARL), - Real64 const EP_UNUSED(TAUBF_BB_PARL), - Real64 const EP_UNUSED(TAUBF_BD_PARL), + [[maybe_unused]] Real64 const RHOBF_BT_PARL, + [[maybe_unused]] Real64 const TAUBF_BB_PARL, + [[maybe_unused]] Real64 const TAUBF_BD_PARL, Real64 const RHOFF_BT_PERP, Real64 const TAUFF_BB_PERP, Real64 const TAUFF_BD_PERP, @@ -3069,16 +3069,16 @@ namespace WindowEquivalentLayer { RHO_BD = (RHOFF_BT_PARL + TAUBF_DD * G1 + G7) / 2.0; } - void PD_BEAM_CASE_IV(Real64 const S, // pleat spacing (> 0) - Real64 const W, // pleat depth (>=0, same units as S) - Real64 const EP_UNUSED(OMEGA_H), // horizontal profile angle, radians - Real64 const EP_UNUSED(DE), // width of illumination on pleat bottom (same units as S) + void PD_BEAM_CASE_IV(Real64 const S, // pleat spacing (> 0) + Real64 const W, // pleat depth (>=0, same units as S) + [[maybe_unused]] Real64 const OMEGA_H, // horizontal profile angle, radians + [[maybe_unused]] Real64 const DE, // width of illumination on pleat bottom (same units as S) Real64 const RHOFF_BT_PARL, Real64 const TAUFF_BB_PARL, Real64 const TAUFF_BD_PARL, - Real64 const EP_UNUSED(RHOBF_BT_PARL), - Real64 const EP_UNUSED(TAUBF_BB_PARL), - Real64 const EP_UNUSED(TAUBF_BD_PARL), + [[maybe_unused]] Real64 const RHOBF_BT_PARL, + [[maybe_unused]] Real64 const TAUBF_BB_PARL, + [[maybe_unused]] Real64 const TAUBF_BD_PARL, Real64 const RHOFF_BT_PERP, Real64 const TAUFF_BB_PERP, Real64 const TAUFF_BD_PERP, @@ -3258,9 +3258,9 @@ namespace WindowEquivalentLayer { Real64 const RHOFF_BT_PARL, Real64 const TAUFF_BB_PARL, Real64 const TAUFF_BD_PARL, - Real64 const EP_UNUSED(RHOBF_BT_PARL), - Real64 const EP_UNUSED(TAUBF_BB_PARL), - Real64 const EP_UNUSED(TAUBF_BD_PARL), + [[maybe_unused]] Real64 const RHOBF_BT_PARL, + [[maybe_unused]] Real64 const TAUBF_BB_PARL, + [[maybe_unused]] Real64 const TAUBF_BD_PARL, Real64 const RHOFF_BT_PERP, Real64 const TAUFF_BB_PERP, Real64 const TAUFF_BD_PERP, @@ -3480,22 +3480,22 @@ namespace WindowEquivalentLayer { RHO_BD = (RHOFF_BT_PARL + TAUBF_DD * G1 + G5) / 2.0; } - void PD_BEAM_CASE_VI(Real64 const S, // pleat spacing (> 0) - Real64 const W, // pleat depth (>=0, same units as S) - Real64 const EP_UNUSED(OMEGA_H), // horizontal profile angle, radians - Real64 const EP_UNUSED(DE), // width of illumination on pleat bottom (same units as S) + void PD_BEAM_CASE_VI(Real64 const S, // pleat spacing (> 0) + Real64 const W, // pleat depth (>=0, same units as S) + [[maybe_unused]] Real64 const OMEGA_H, // horizontal profile angle, radians + [[maybe_unused]] Real64 const DE, // width of illumination on pleat bottom (same units as S) Real64 const RHOFF_BT_PARL, Real64 const TAUFF_BB_PARL, Real64 const TAUFF_BD_PARL, - Real64 const EP_UNUSED(RHOBF_BT_PARL), - Real64 const EP_UNUSED(TAUBF_BB_PARL), - Real64 const EP_UNUSED(TAUBF_BD_PARL), - Real64 const EP_UNUSED(RHOFF_BT_PERP), - Real64 const EP_UNUSED(TAUFF_BB_PERP), - Real64 const EP_UNUSED(TAUFF_BD_PERP), - Real64 const EP_UNUSED(RHOBF_BT_PERP), - Real64 const EP_UNUSED(TAUBF_BB_PERP), - Real64 const EP_UNUSED(TAUBF_BD_PERP), + [[maybe_unused]] Real64 const RHOBF_BT_PARL, + [[maybe_unused]] Real64 const TAUBF_BB_PARL, + [[maybe_unused]] Real64 const TAUBF_BD_PARL, + [[maybe_unused]] Real64 const RHOFF_BT_PERP, + [[maybe_unused]] Real64 const TAUFF_BB_PERP, + [[maybe_unused]] Real64 const TAUFF_BD_PERP, + [[maybe_unused]] Real64 const RHOBF_BT_PERP, + [[maybe_unused]] Real64 const TAUBF_BB_PERP, + [[maybe_unused]] Real64 const TAUBF_BD_PERP, Real64 const RHOBF_DD, // fabric back diffuse-diffuse reflectance Real64 const RHOFF_DD, // fabric front diffuse-diffuse reflectance Real64 const TAUFF_DD, // fabric front diffuse-diffuse transmittance @@ -5899,10 +5899,10 @@ namespace WindowEquivalentLayer { Real64 const CK, Real64 const ACP, // gas specific heat coeffs, CP = ACP + BCP*TM + CCP*TM*TM Real64 const BCP, - Real64 const EP_UNUSED(CCP), + [[maybe_unused]] Real64 const CCP, Real64 const AVISC, // gas viscosity coeffs, VISC = AVISC + BVISC*TM + CVISC*TM*TM Real64 const BVISC, - Real64 const EP_UNUSED(CVISC), + [[maybe_unused]] Real64 const CVISC, Real64 const RHOGAS // gas density, kg/m3 ) { @@ -6947,9 +6947,9 @@ namespace WindowEquivalentLayer { } Real64 Specular_F(EnergyPlusData &state, - Real64 const THETA, // incidence angle, radians - int const OPT, // options (unused) - const Array1D &EP_UNUSED(P) // parameters (none defined) + Real64 const THETA, // incidence angle, radians + int const OPT, // options (unused) + [[maybe_unused]] const Array1D &P // parameters (none defined) ) { // FUNCTION INFORMATION: diff --git a/src/EnergyPlus/WindowManagerExteriorOptical.cc b/src/EnergyPlus/WindowManagerExteriorOptical.cc index a5899d6222f..451783fa027 100644 --- a/src/EnergyPlus/WindowManagerExteriorOptical.cc +++ b/src/EnergyPlus/WindowManagerExteriorOptical.cc @@ -324,7 +324,7 @@ namespace WindowManager { { } - void CWCEMaterialDualBandFactory::init(EnergyPlusData &EP_UNUSED(state)) + void CWCEMaterialDualBandFactory::init([[maybe_unused]] EnergyPlusData &state) { if (m_Range == WavelengthRange::Visible) { m_Material = createVisibleRangeMaterial(); diff --git a/src/EnergyPlus/WindowManagerExteriorOptical.hh b/src/EnergyPlus/WindowManagerExteriorOptical.hh index 349978b7722..bb416fb8e64 100644 --- a/src/EnergyPlus/WindowManagerExteriorOptical.hh +++ b/src/EnergyPlus/WindowManagerExteriorOptical.hh @@ -153,7 +153,7 @@ namespace WindowManager { const FenestrationCommon::WavelengthRange t_Range); protected: - void init(EnergyPlusData &EP_UNUSED(state)) override; + void init([[maybe_unused]] EnergyPlusData &state) override; virtual std::shared_ptr createVisibleRangeMaterial() = 0; virtual std::shared_ptr createSolarRangeMaterial() = 0; }; diff --git a/src/EnergyPlus/ZoneDehumidifier.cc b/src/EnergyPlus/ZoneDehumidifier.cc index 27e0aa32b67..1de55812f41 100644 --- a/src/EnergyPlus/ZoneDehumidifier.cc +++ b/src/EnergyPlus/ZoneDehumidifier.cc @@ -115,12 +115,12 @@ namespace ZoneDehumidifier { using namespace ScheduleManager; void SimZoneDehumidifier(EnergyPlusData &state, - std::string const &CompName, // Name of the zone dehumidifier - int const ZoneNum, // Number of zone being served - bool const EP_UNUSED(FirstHVACIteration), // TRUE if 1st HVAC simulation of system timestep - Real64 &QSensOut, // Sensible capacity delivered to zone (W) - Real64 &QLatOut, // Latent capacity delivered to zone (kg/s), dehumidify = negative - int &CompIndex // Index to the zone dehumidifier + std::string const &CompName, // Name of the zone dehumidifier + int const ZoneNum, // Number of zone being served + [[maybe_unused]] bool const FirstHVACIteration, // TRUE if 1st HVAC simulation of system timestep + Real64 &QSensOut, // Sensible capacity delivered to zone (W) + Real64 &QLatOut, // Latent capacity delivered to zone (kg/s), dehumidify = negative + int &CompIndex // Index to the zone dehumidifier ) { diff --git a/src/EnergyPlus/ZoneTempPredictorCorrector.cc b/src/EnergyPlus/ZoneTempPredictorCorrector.cc index d4ce25ceeae..70ad80aeb0e 100644 --- a/src/EnergyPlus/ZoneTempPredictorCorrector.cc +++ b/src/EnergyPlus/ZoneTempPredictorCorrector.cc @@ -5583,8 +5583,8 @@ namespace ZoneTempPredictorCorrector { Real64 &oldVal0, Real64 &oldVal1, Real64 &oldVal2, - Real64 &EP_UNUSED(oldVal3), - Real64 &EP_UNUSED(oldVal4), + [[maybe_unused]] Real64 &oldVal3, + [[maybe_unused]] Real64 &oldVal4, Real64 &newVal0, Real64 &newVal1, Real64 &newVal2, diff --git a/src/EnergyPlus/api/datatransfer.cc b/src/EnergyPlus/api/datatransfer.cc index dacc480ae56..f28650277d0 100644 --- a/src/EnergyPlus/api/datatransfer.cc +++ b/src/EnergyPlus/api/datatransfer.cc @@ -629,12 +629,14 @@ int minutes(EnergyPlusState state) { return (int)(fractionalMinutesIntoTheDay); } -int numTimeStepsInHour(EnergyPlusState state) { +int numTimeStepsInHour([[maybe_unused]] EnergyPlusState state) +{ auto *thisState = reinterpret_cast(state); return thisState->dataGlobal->NumOfTimeStepInHour; } -int zoneTimeStepNum(EnergyPlusState state) { +int zoneTimeStepNum([[maybe_unused]] EnergyPlusState state) +{ auto *thisState = reinterpret_cast(state); return thisState->dataGlobal->TimeStep; } diff --git a/src/EnergyPlus/api/runtime.cc b/src/EnergyPlus/api/runtime.cc index 209fc75b291..03f97bc3f1e 100644 --- a/src/EnergyPlus/api/runtime.cc +++ b/src/EnergyPlus/api/runtime.cc @@ -90,7 +90,8 @@ void registerProgressCallback(EnergyPlusState state, void (*f)(int const)) { thisState->dataGlobal->progressCallback = f; } -void registerStdOutCallback(EnergyPlusState state, std::function f) { +void registerStdOutCallback([[maybe_unused]] EnergyPlusState state, std::function f) +{ auto *thisState = reinterpret_cast(state); thisState->dataGlobal->messageCallback = f; } diff --git a/tst/EnergyPlus/unit/Fixtures/EnergyPlusFixture.cc b/tst/EnergyPlus/unit/Fixtures/EnergyPlusFixture.cc index 228af0d0437..9a36c5fe524 100644 --- a/tst/EnergyPlus/unit/Fixtures/EnergyPlusFixture.cc +++ b/tst/EnergyPlus/unit/Fixtures/EnergyPlusFixture.cc @@ -388,13 +388,13 @@ bool EnergyPlusFixture::process_idd(std::string const &idd, bool &errors_found) return errors_found; } -bool EnergyPlusFixture::compare_idf(std::string const &EP_UNUSED(name), - int const EP_UNUSED(num_alphas), - int const EP_UNUSED(num_numbers), - std::vector const &EP_UNUSED(alphas), - std::vector const &EP_UNUSED(alphas_blank), - std::vector const &EP_UNUSED(numbers), - std::vector const &EP_UNUSED(numbers_blank)) +bool EnergyPlusFixture::compare_idf([[maybe_unused]] std::string const &name, + [[maybe_unused]] int const num_alphas, + [[maybe_unused]] int const num_numbers, + [[maybe_unused]] std::vector const &alphas, + [[maybe_unused]] std::vector const &alphas_blank, + [[maybe_unused]] std::vector const &numbers, + [[maybe_unused]] std::vector const &numbers_blank) { // using namespace InputProcessor;