@@ -362,28 +362,30 @@ template <at... Ats> constexpr inline auto field_size = (0u + ... + Ats.size());
362362
363363template <typename T, T V = T{}> struct with_default {
364364 constexpr static auto default_value = V;
365- template <typename F> using default_matcher_t = msg::equal_to_t <F, V>;
366365 using is_mutable_t = void ;
367366 template <T X> constexpr static auto is_compatible_value = true ;
368367};
369368
370369template <typename T, T V = T{}> struct with_const_default {
371370 constexpr static auto default_value = V;
372- template <typename F> using default_matcher_t = msg::equal_to_t <F, V>;
373371 template <T X> constexpr static auto is_compatible_value = X == V;
374372};
375373
376374struct without_default {
377- template <typename F> using default_matcher_t = match::never_t ;
378375 using is_mutable_t = void ;
379376 template <auto X> constexpr static auto is_compatible_value = true ;
380377};
381378
379+ struct uninitialized {
380+ template <auto X> constexpr static auto is_compatible_value = true ;
381+ };
382+
382383template <typename T>
383384concept has_default_value = requires { T::default_value; };
384385
385386template <typename T>
386- using has_default_value_t = std::bool_constant<has_default_value<T>>;
387+ using initializable_t = std::bool_constant<has_default_value<T> or
388+ std::is_base_of_v<uninitialized, T>>;
387389
388390template <typename T>
389391concept is_mutable_value = requires { typename T::is_mutable_t ; };
@@ -489,6 +491,8 @@ class field_t : public field_spec_t<Name, T, detail::field_size<Ats...>>,
489491 using without_default =
490492 field_t <Name, T, detail::without_default, M, Ats...>;
491493
494+ using uninitialized = field_t <Name, T, detail::uninitialized, M, Ats...>;
495+
492496 // ======================================================================
493497 // matcher values
494498 template <typename NewMatcher>
0 commit comments