diff --git a/src/Corrade/Containers/StridedArrayView.h b/src/Corrade/Containers/StridedArrayView.h index 2f65df18e..9330c18be 100644 --- a/src/Corrade/Containers/StridedArrayView.h +++ b/src/Corrade/Containers/StridedArrayView.h @@ -1910,6 +1910,13 @@ template class StridedIterator { #ifndef DOXYGEN_GENERATING_OUTPUT /*implicit*/ StridedIterator(typename std::conditional::value, const void, void>::type* data, const StridedDimensions& size, const StridedDimensions& stride, std::size_t i) noexcept: _data{data}, _size{size}, _stride{stride}, _i{i} {} + + #ifdef CORRADE_MSVC2015_COMPATIBILITY + /* Needed by MSVC 2015 to make StridedIterator usable with + std::unique() -- it wants to default-construct it, for some reason. + See StridedArrayViewStlTest::unique() for a repro case. */ + /*implicit*/ StridedIterator(): _data{}, _size{}, _stride{}, _i{} {} + #endif #endif /** @brief Equality comparison */