Skip to content

Commit

Permalink
minor cleanup, but with C++17 features
Browse files Browse the repository at this point in the history
  • Loading branch information
mitchute committed Nov 18, 2020
1 parent ffedb26 commit e0f4807
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/EnergyPlus/CurveManager.cc
Original file line number Diff line number Diff line change
Expand Up @@ -2709,7 +2709,7 @@ namespace CurveManager {
using namespace DataIPShortCuts;

// SUBROUTINE PARAMETER DEFINITIONS:
constexpr auto CurveObjectName = "Curve:Functional:PressureDrop";
constexpr std::string_view CurveObjectName = "Curve:Functional:PressureDrop";

// SUBROUTINE LOCAL VARIABLE DECLARATIONS:
int NumPressure;
Expand All @@ -2721,11 +2721,11 @@ namespace CurveManager {
bool ErrsFound(false); // Set to true if errors in input, fatal at end of routine
int CurveNum;

NumPressure = inputProcessor->getNumObjectsFound(state, CurveObjectName);
NumPressure = inputProcessor->getNumObjectsFound(state, CurveObjectName.data());
DataBranchAirLoopPlant::PressureCurve.allocate(NumPressure);
for (CurveNum = 1; CurveNum <= NumPressure; ++CurveNum) {
inputProcessor->getObjectItem(state,
CurveObjectName,
CurveObjectName.data(),
CurveNum,
Alphas,
NumAlphas,
Expand All @@ -2736,7 +2736,7 @@ namespace CurveManager {
_,
cAlphaFieldNames,
cNumericFieldNames);
GlobalNames::VerifyUniqueInterObjectName(state, state.dataCurveManager->UniqueCurveNames, Alphas(1), CurveObjectName, cAlphaFieldNames(1), ErrsFound);
GlobalNames::VerifyUniqueInterObjectName(state, state.dataCurveManager->UniqueCurveNames, Alphas(1), CurveObjectName.data(), cAlphaFieldNames(1), ErrsFound);
DataBranchAirLoopPlant::PressureCurve(CurveNum).Name = Alphas(1);
DataBranchAirLoopPlant::PressureCurve(CurveNum).EquivDiameter = Numbers(1);
DataBranchAirLoopPlant::PressureCurve(CurveNum).MinorLossCoeff = Numbers(2);
Expand Down

5 comments on commit e0f4807

@nrel-bot-2b
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

global_dataAirSystems (mitchute) - x86_64-Linux-Ubuntu-18.04-gcc-7.5: OK (3034 of 3034 tests passed, 0 test warnings)

Build Badge Test Badge

@nrel-bot-3
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

global_dataAirSystems (mitchute) - x86_64-MacOS-10.15-clang-11.0.0: OK (2994 of 2994 tests passed, 0 test warnings)

Build Badge Test Badge

@nrel-bot-2c
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

global_dataAirSystems (mitchute) - x86_64-Linux-Ubuntu-18.04-gcc-7.5-UnitTestsCoverage-Debug: OK (1558 of 1558 tests passed, 0 test warnings)

Build Badge Test Badge Coverage Badge

@nrel-bot-2b
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

global_dataAirSystems (mitchute) - x86_64-Linux-Ubuntu-18.04-gcc-7.5-IntegrationCoverage-Debug: OK (722 of 722 tests passed, 0 test warnings)

Build Badge Test Badge Coverage Badge

@nrel-bot
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

global_dataAirSystems (mitchute) - Win64-Windows-10-VisualStudio-16: OK (2250 of 2250 tests passed, 0 test warnings)

Build Badge Test Badge

Please sign in to comment.