From 4fcc33c5e5e527dc6e69e7eff7a83c2df8a4a8fa Mon Sep 17 00:00:00 2001 From: Jason Cobb Date: Sun, 15 Mar 2020 18:38:13 -0400 Subject: [PATCH] Remove byte-reinterpret conversion operator from vector_ref --- libsolutil/vector_ref.h | 1 - 1 file changed, 1 deletion(-) diff --git a/libsolutil/vector_ref.h b/libsolutil/vector_ref.h index 3bb71f35e..46901a46e 100644 --- a/libsolutil/vector_ref.h +++ b/libsolutil/vector_ref.h @@ -44,7 +44,6 @@ public: std::vector toBytes() const { return std::vector(reinterpret_cast(m_data), reinterpret_cast(m_data) + m_count * sizeof(T)); } std::string toString() const { return std::string((char const*)m_data, ((char const*)m_data) + m_count * sizeof(T)); } - template explicit operator vector_ref() const { assert(m_count * sizeof(T) / sizeof(T2) * sizeof(T2) / sizeof(T) == m_count); return vector_ref(reinterpret_cast(m_data), m_count * sizeof(T) / sizeof(T2)); } operator vector_ref() const { return vector_ref(m_data, m_count); } T* data() const { return m_data; }