3#include <userver/storages/postgres/io/type_mapping.hpp>
10inline constexpr bool kShouldInitMapping =
requires { T::init; };
13struct BufferParserBase {
17 explicit BufferParserBase(ValueType& v)
20 using PgMapping = CppToPg<ValueType>;
21 if constexpr (kShouldInitMapping<PgMapping>) {
22 ForceReference(PgMapping::init);
28struct BufferParserBase<T&&> {
32 explicit BufferParserBase(ValueType&& v)
35 using PgMapping = CppToPg<ValueType>;
36 if constexpr (kShouldInitMapping<PgMapping>) {
37 ForceReference(PgMapping::init);
43struct BufferFormatterBase {
45 const ValueType& value;
46 explicit BufferFormatterBase(
const ValueType& v)