@@ -141,27 +141,6 @@ struct ReadDestUpdate
141
141
Value& m_value;
142
142
};
143
143
144
- template <typename LocalType, typename Input, typename ReadDest>
145
- decltype (auto ) CustomReadField(TypeList<std::optional<LocalType>>,
146
- Priority<1 >,
147
- InvokeContext& invoke_context,
148
- Input&& input,
149
- ReadDest&& read_dest)
150
- {
151
- return read_dest.update ([&](auto & value) {
152
- if (!input.has ()) {
153
- value.reset ();
154
- } else if (value) {
155
- ReadField (TypeList<LocalType>(), invoke_context, input, ReadDestUpdate (*value));
156
- } else {
157
- ReadField (TypeList<LocalType>(), invoke_context, input,
158
- ReadDestEmplace (TypeList<LocalType>(), [&](auto &&... args) -> auto & {
159
- value.emplace (std::forward<decltype (args)>(args)...);
160
- return *value;
161
- }));
162
- }
163
- });
164
- }
165
144
166
145
template <typename LocalType, typename Input, typename ReadDest>
167
146
decltype (auto ) CustomReadField(TypeList<std::shared_ptr<LocalType>>,
@@ -824,20 +803,6 @@ LocalType BuildPrimitive(InvokeContext& invoke_context,
824
803
return value;
825
804
}
826
805
827
- template <typename LocalType, typename Value, typename Output>
828
- void CustomBuildField (TypeList<std::optional<LocalType>>,
829
- Priority<1 >,
830
- InvokeContext& invoke_context,
831
- Value&& value,
832
- Output&& output)
833
- {
834
- if (value) {
835
- output.setHas ();
836
- // FIXME: should std::move value if destvalue is rref?
837
- BuildField (TypeList<LocalType>(), invoke_context, output, *value);
838
- }
839
- }
840
-
841
806
template <typename Output>
842
807
void CustomBuildField (TypeList<std::exception >,
843
808
Priority<1 >,
0 commit comments