Skip to content

Commit

Permalink
Windows fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
Pöschel authored and franzpoeschel committed Feb 16, 2024
1 parent 993262f commit b5e4217
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 4 deletions.
3 changes: 2 additions & 1 deletion include/openPMD/snapshots/ContainerTraits.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@ class OpaqueSeriesIterator
friend class Series;
friend class StatefulSnapshotsContainer;
friend class RandomAccessIteratorContainer;
using parent_t = AbstractSeriesIterator<OpaqueSeriesIterator>;
using parent_t =
AbstractSeriesIterator<OpaqueSeriesIterator, value_type_in>;
// no shared_ptr since copied iterators should not share state
std::unique_ptr<DynamicSeriesIterator<value_type_in>> m_internal_iterator;

Expand Down
4 changes: 3 additions & 1 deletion include/openPMD/snapshots/RandomAccessIterator.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,9 @@ class RandomAccessIterator
{
private:
friend class RandomAccessIteratorContainer;
using parent_t = AbstractSeriesIterator<RandomAccessIterator<iterator_t>>;
using parent_t = AbstractSeriesIterator<
RandomAccessIterator<iterator_t>,
detail::iterator_to_value_type<iterator_t>>;

RandomAccessIterator(iterator_t it);

Expand Down
4 changes: 3 additions & 1 deletion include/openPMD/snapshots/StatefulIterator.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,9 @@ class StatefulIterator
auto get() -> SharedData &;
auto get() const -> SharedData const &;

using parent_t = AbstractSeriesIterator<StatefulIterator>;
using parent_t = AbstractSeriesIterator<
StatefulIterator,
Container<Iteration, Iteration::IterationIndex_t>::value_type>;

public:
using value_type =
Expand Down
1 change: 1 addition & 0 deletions src/IO/ADIOS/ADIOS2IOHandler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1588,6 +1588,7 @@ detail::ADIOS2File &ADIOS2IOHandlerImpl::getFileData(
{
return *it->second;
}
throw std::runtime_error("Unreachable!");
}

void ADIOS2IOHandlerImpl::dropFileData(InvalidatableFile const &file)
Expand Down
2 changes: 1 addition & 1 deletion src/snapshots/StatefulIterator.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -535,7 +535,6 @@ std::optional<StatefulIterator *> StatefulIterator::loopBody()
try
{
iterations.at(current_iteration).open();
[[fallthrough]];
}
catch (error::ReadError const &err)
{
Expand All @@ -545,6 +544,7 @@ std::optional<StatefulIterator *> StatefulIterator::loopBody()
option.value()->deactivateDeadIteration(current_iteration);
return std::nullopt;
}
[[fallthrough]];
case internal::CloseStatus::Open:
return option;
case internal::CloseStatus::ClosedInBackend:
Expand Down

0 comments on commit b5e4217

Please sign in to comment.