Skip to content

Commit 27a4886

Browse files
committed
Fix after rebase
1 parent 450c9da commit 27a4886

File tree

2 files changed

+18
-15
lines changed

2 files changed

+18
-15
lines changed

include/openPMD/IO/ADIOS/macros.hpp

Lines changed: 16 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -21,25 +21,28 @@
2121
#define openPMD_HAVE_ADIOS2_BP5 0
2222
#endif
2323

24-
namespace detail
25-
{
26-
template <typename Variable, typename SFINAE = void>
27-
struct CanTheMemorySelectionBeReset
24+
namespace openPMD
2825
{
29-
static constexpr bool value = false;
30-
};
31-
32-
template <typename Variable>
33-
struct CanTheMemorySelectionBeReset<
34-
Variable,
35-
decltype(std::declval<Variable>().SetMemorySelection())>
26+
namespace detail
3627
{
37-
static constexpr bool value = true;
38-
};
28+
template <typename Variable, typename SFINAE = void>
29+
struct CanTheMemorySelectionBeReset
30+
{
31+
static constexpr bool value = false;
32+
};
33+
34+
template <typename Variable>
35+
struct CanTheMemorySelectionBeReset<
36+
Variable,
37+
decltype(std::declval<Variable>().SetMemorySelection())>
38+
{
39+
static constexpr bool value = true;
40+
};
3941
} // namespace detail
4042

4143
constexpr bool CanTheMemorySelectionBeReset =
4244
detail::CanTheMemorySelectionBeReset<adios2::Variable<int>>::value;
45+
} // namespace openPMD
4346

4447
#else
4548

src/IO/ADIOS/ADIOS2File.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ void WriteDataset::call(ADIOS2File &ba, detail::BufferedPut &bp)
121121
engine.Put(var, ptr);
122122
if (bp.param.memorySelection.has_value())
123123
{
124-
if constexpr (CanTheMemorySelectionBeReset)
124+
if constexpr (openPMD::CanTheMemorySelectionBeReset)
125125
{
126126
var.SetMemorySelection();
127127
}
@@ -207,7 +207,7 @@ struct RunUniquePtrPut
207207
engine.Put(var, ptr);
208208
if (bufferedPut.memorySelection.has_value())
209209
{
210-
if constexpr (CanTheMemorySelectionBeReset)
210+
if constexpr (openPMD::CanTheMemorySelectionBeReset)
211211
{
212212
var.SetMemorySelection();
213213
}

0 commit comments

Comments
 (0)