From 2fad6761905838f0b60b9d97eeca71e5675dc98e Mon Sep 17 00:00:00 2001 From: Dmitrii Kamaldinov Date: Sat, 18 May 2019 20:21:59 +0300 Subject: [PATCH] int8vector str and repr --- pysdsl/io.hpp | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/pysdsl/io.hpp b/pysdsl/io.hpp index 824591f..2e8955b 100644 --- a/pysdsl/io.hpp +++ b/pysdsl/io.hpp @@ -28,9 +28,13 @@ decltype(auto) to_string(const T &self, const size_t max_elements=100, for (auto i = detail::cbegin(self); i != detail::cend(self); i++) { if (count) fout << sep; - const value_type value = *i; - - fout << value; + if constexpr (std::is_same::value) { + const uint64_t value = *i; + fout << value; + } else { + const value_type value = *i; + fout << value; + } if (max_elements > 0 && count >= max_elements) { fout << sep << "...(" << self.size() << " elements)";