From a62088539ed02a8569814601b3b99b713c5d8a34 Mon Sep 17 00:00:00 2001 From: Lioncash Date: Wed, 12 Jun 2019 17:27:06 -0400 Subject: common/hex_util: Combine HexVectorToString() and HexArrayToString() These can be generified together by using a concept type to designate them. This also has the benefit of not making copies of potentially very large arrays. --- src/common/hex_util.cpp | 7 ------- 1 file changed, 7 deletions(-) (limited to 'src/common/hex_util.cpp') diff --git a/src/common/hex_util.cpp b/src/common/hex_util.cpp index 5b63f9e81..c2f6cf0f6 100644 --- a/src/common/hex_util.cpp +++ b/src/common/hex_util.cpp @@ -30,13 +30,6 @@ std::vector HexStringToVector(std::string_view str, bool little_endian) { return out; } -std::string HexVectorToString(const std::vector& vector, bool upper) { - std::string out; - for (u8 c : vector) - out += fmt::format(upper ? "{:02X}" : "{:02x}", c); - return out; -} - std::array operator""_array16(const char* str, std::size_t len) { if (len != 32) { LOG_ERROR(Common, -- cgit v1.2.3