7#include <userver/chaotic/convert/to.hpp>
8#include <userver/chaotic/io/std/uint32_t.hpp>
9#include <userver/utils/numeric_cast.hpp>
11USERVER_NAMESPACE_BEGIN
13namespace chaotic::convert {
17 std::is_integral_v<T> && !std::is_same_v<
unsigned, std::uint32_t>, T>
18Convert(
unsigned value, To<T>) {
19 return utils::numeric_cast<T>(value);
24 std::is_integral_v<T> && !std::is_same_v<
unsigned, std::uint32_t>,
unsigned>
25Convert(
const T& value, To<
unsigned>) {
26 return utils::numeric_cast<
unsigned>(value);