From daf935d310701c34872c5f5a56432b51be5c7368 Mon Sep 17 00:00:00 2001
From: Max Kellermann <mk@cm4all.com>
Date: Mon, 7 Aug 2023 12:31:24 +0200
Subject: [PATCH] util/HexFormat: add non-const overload

---
 src/util/HexFormat.hxx | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/src/util/HexFormat.hxx b/src/util/HexFormat.hxx
index fcc893326..8d5eef7f4 100644
--- a/src/util/HexFormat.hxx
+++ b/src/util/HexFormat.hxx
@@ -82,3 +82,11 @@ HexFormat(std::span<const std::byte, size> input) noexcept
 	HexFormat(output.data(), input);
 	return output;
 }
+
+template<std::size_t size>
+constexpr auto
+HexFormat(std::span<std::byte, size> input) noexcept
+{
+	std::span<const std::byte, size> const_input{input};
+	return HexFormat(const_input);
+}