BAN: add helper to cast Span<T> to Span<const T>

This commit is contained in:
2023-10-20 04:59:08 +03:00
parent c17cdb39d5
commit 61c7a68f4a
5 changed files with 34 additions and 23 deletions

View File

@@ -43,6 +43,8 @@ namespace BAN
Span slice(size_type, size_type = ~size_type(0));
Span<const T> as_const() const { return Span<const T>(m_data, m_size); }
private:
T* m_data = nullptr;
size_type m_size = 0;