Commit f83cb633 authored by Dominik Charousset's avatar Dominik Charousset

Fix stringification of containers

parent 6ecfdc74
......@@ -175,7 +175,12 @@ public:
template <class T, class... Ts>
void traverse(const meta::hex_formatted_t&, const T& x, const Ts&... xs) {
sep();
if constexpr (std::is_integral<T>::value) {
append_hex(result_, x);
} else {
static_assert(sizeof(typename T::value_type) == 1);
append_hex(result_, x.data(), x.size());
}
traverse(xs...);
}
......
......@@ -53,7 +53,7 @@ void append_percent_encoded(std::string& str, string_view x, bool is_path) {
case ';':
case '=':
str += '%';
append_hex(str, reinterpret_cast<uint8_t*>(&ch), 1);
append_hex(str, ch);
break;
default:
str += ch;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment