@@ -220,7 +220,7 @@ WriteBuffer::WriteBuffer(WriteBuffer &&) noexcept = default;
220220WriteBuffer &WriteBuffer::operator =(WriteBuffer &&) noexcept = default ;
221221
222222template <typename T>
223- WriteBuffer const &WriteBuffer::operator =(std::shared_ptr<T> const &ptr)
223+ WriteBuffer &WriteBuffer::operator =(std::shared_ptr<T> const &ptr)
224224{
225225 if constexpr (std::is_const_v<T>)
226226 {
@@ -234,7 +234,7 @@ WriteBuffer const &WriteBuffer::operator=(std::shared_ptr<T> const &ptr)
234234 }
235235 return *this ;
236236}
237- WriteBuffer const &WriteBuffer::operator =(UniquePtrWithLambda<void > ptr)
237+ WriteBuffer &WriteBuffer::operator =(UniquePtrWithLambda<void > ptr)
238238{
239239 m_buffer =
240240 std::make_any<WriteBufferTypes>(CopyableUniquePtr (std::move (ptr)));
@@ -254,17 +254,14 @@ void const *WriteBuffer::get() const
254254
255255#define OPENPMD_INSTANTIATE (dtype ) \
256256 template WriteBuffer::WriteBuffer(std::shared_ptr<dtype>); \
257- template WriteBuffer const &WriteBuffer::operator =( \
257+ template WriteBuffer &WriteBuffer::operator =( \
258258 std::shared_ptr<dtype> const &);
259259
260- // currently not instantiating <T const> types, this class is internal and we
261- // dont need it
262- OPENPMD_FOREACH_DATASET_DATATYPE (OPENPMD_INSTANTIATE)
260+ OPENPMD_FOREACH_NONVECTOR_DATATYPE (OPENPMD_INSTANTIATE)
263261template WriteBuffer::WriteBuffer(std::shared_ptr<void >);
264- template WriteBuffer const &
265- WriteBuffer::operator =(std::shared_ptr<void > const &);
262+ template WriteBuffer &WriteBuffer::operator =(std::shared_ptr<void > const &);
266263template WriteBuffer::WriteBuffer(std::shared_ptr<void const >);
267- template WriteBuffer const &
264+ template WriteBuffer &
268265WriteBuffer::operator =(std::shared_ptr<void const > const &);
269266#undef OPENPMD_INSTANTIATE
270267} // namespace openPMD::auxiliary
0 commit comments