Skip to content

Commit 4381409

Browse files
committed
cleanup
1 parent ba1d0ff commit 4381409

File tree

2 files changed

+22
-22
lines changed

2 files changed

+22
-22
lines changed

include/openPMD/toolkit/ExternalBlockStorage.hpp

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -82,9 +82,9 @@ class ExternalBlockStorage
8282
// returns created JSON key
8383
template <typename DatatypeHandling, typename T>
8484
auto store(
85-
Extent globalExtent,
86-
Offset blockOffset,
87-
Extent blockExtent,
85+
Extent const &globalExtent,
86+
Offset const &blockOffset,
87+
Extent const &blockExtent,
8888
nlohmann::json &fullJsonDataset,
8989
nlohmann::json::json_pointer const &path,
9090
std::optional<std::string> infix, // e.g. for distinguishing MPI ranks
@@ -93,14 +93,14 @@ class ExternalBlockStorage
9393
template <typename DatatypeHandling, typename T>
9494
void read(
9595
std::string const &identifier,
96-
nlohmann::json &fullJsonDataset,
96+
nlohmann::json const &fullJsonDataset,
9797
nlohmann::json::json_pointer const &path,
9898
T *data);
9999

100100
template <typename DatatypeHandling, typename T>
101101
void read(
102-
Offset blockOffset,
103-
Extent blockExtent,
102+
Offset const &blockOffset,
103+
Extent const &blockExtent,
104104
nlohmann::json const &fullJsonDataset,
105105
nlohmann::json::json_pointer const &path,
106106
T *data);

src/toolkit/ExternalBlockStorage.cpp

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -63,9 +63,9 @@ auto ExternalBlockStorage::makeAwsSession(
6363

6464
template <typename DatatypeHandling, typename T>
6565
auto ExternalBlockStorage::store(
66-
Extent globalExtent,
67-
Offset blockOffset,
68-
Extent blockExtent,
66+
Extent const &globalExtent,
67+
Offset const &blockOffset,
68+
Extent const &blockExtent,
6969
nlohmann::json &fullJsonDataset,
7070
nlohmann::json::json_pointer const &path,
7171
std::optional<std::string> infix,
@@ -157,16 +157,16 @@ auto ExternalBlockStorage::store(
157157

158158
template <typename DatatypeHandling, typename T>
159159
void ExternalBlockStorage::read(
160-
std::string const &identifier,
161-
nlohmann::json &fullJsonDataset,
162-
nlohmann::json::json_pointer const &path,
163-
T *data)
160+
[[maybe_unused]] std::string const &identifier,
161+
[[maybe_unused]] nlohmann::json const &fullJsonDataset,
162+
[[maybe_unused]] nlohmann::json::json_pointer const &path,
163+
[[maybe_unused]] T *data)
164164
{}
165165

166166
template <typename DatatypeHandling, typename T>
167167
void ExternalBlockStorage::read(
168-
Offset blockOffset,
169-
Extent blockExtent,
168+
Offset const &blockOffset,
169+
Extent const &blockExtent,
170170
nlohmann::json const &fullJsonDataset,
171171
nlohmann::json::json_pointer const &path,
172172
T *data)
@@ -232,21 +232,21 @@ void ExternalBlockStorage::sanitizeString(std::string &s)
232232

233233
#define OPENPMD_INSTANTIATE_DATATYPEHANDLING(datatypehandling, type) \
234234
template auto ExternalBlockStorage::store<datatypehandling, type>( \
235-
Extent globalExtent, \
236-
Offset blockOffset, \
237-
Extent blockExtent, \
238-
nlohmann::json & fullJsonDataset, \
235+
Extent const &globalExtent, \
236+
Offset const &blockOffset, \
237+
Extent const &blockExtent, \
238+
nlohmann::json &fullJsonDataset, \
239239
nlohmann::json::json_pointer const &path, \
240240
std::optional<std::string> infix, \
241241
type const *data) -> std::string; \
242242
template void ExternalBlockStorage::read<datatypehandling, type>( \
243243
std::string const &identifier, \
244-
nlohmann::json &fullJsonDataset, \
244+
nlohmann::json const &fullJsonDataset, \
245245
nlohmann::json::json_pointer const &path, \
246246
type *data); \
247247
template void ExternalBlockStorage::read<datatypehandling, type>( \
248-
Offset blockOffset, \
249-
Extent blockExtent, \
248+
Offset const &blockOffset, \
249+
Extent const &blockExtent, \
250250
nlohmann::json const &fullJsonDataset, \
251251
nlohmann::json::json_pointer const &path, \
252252
type *data);

0 commit comments

Comments
 (0)