Skip to content
Snippets Groups Projects
Commit 1c883ba7 authored by Stéphane Del Pino's avatar Stéphane Del Pino
Browse files

Fix CastArray copy_to in the case of empty arrays

parent 0f668693
No related branches found
No related tags found
1 merge request!124Add files for high order integration with quadratures
......@@ -40,9 +40,10 @@ class [[nodiscard]] CastArray
static_assert(not std::is_const_v<ImageCastDataType>);
Assert(source_array.size() == image_array.size());
if (source_array.size() > 0) {
std::copy(source_array.m_values, source_array.m_values + source_array.size(), &image_array[0]);
}
}
PUGS_INLINE
CastArray& operator=(const CastArray&) = default;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment