Skip to content

Commit

Permalink
Fix STStorageGroup output
Browse files Browse the repository at this point in the history
  • Loading branch information
h-fournier committed Dec 20, 2024
1 parent 389b652 commit 55d7e33
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
8 changes: 4 additions & 4 deletions src/libs/antares/study/parts/short-term-storage/container.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -238,18 +238,18 @@ std::pair<Data::ShortTermStorage::Group, Data::ReserveName>
STStorageInput::reserveParticipationGroupAt(const Area* area, unsigned int index) const
{
int column = 0;
for (auto [reserveName, _] : area->allCapacityReservations.areaCapacityReservationsUp)
for (const auto& [reserveName, _]: area->allCapacityReservations.areaCapacityReservationsUp)
{
for (int indexGroup = 0; indexGroup < Data::groupMax; indexGroup++)
for (int indexGroup = 0; indexGroup < Data::ShortTermStorage::groupMax; indexGroup++)
{
if (column == index)
return {static_cast<Data::ShortTermStorage::Group>(indexGroup), reserveName};
column++;
}
}
for (auto [reserveName, _] : area->allCapacityReservations.areaCapacityReservationsDown)
for (const auto& [reserveName, _]: area->allCapacityReservations.areaCapacityReservationsDown)
{
for (int indexGroup = 0; indexGroup < Data::groupMax; indexGroup++)
for (int indexGroup = 0; indexGroup < Data::ShortTermStorage::groupMax; indexGroup++)
{
if (column == index)
return {static_cast<Data::ShortTermStorage::Group>(indexGroup), reserveName};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -114,11 +114,11 @@ static std::string STStorageGroupToString(Data::ShortTermStorage::Group idx)
case Group::Other2:
return "Other2";
case Group::Other3:
return "Other 3";
return "Other3";
case Group::Other4:
return "Other 4";
return "Other4";
case Group::Other5:
return "Other 5";
return "Other5";
default:
return "<unknown>";
}
Expand Down

0 comments on commit 55d7e33

Please sign in to comment.