Feat/286/std expected (#340)

This commit is contained in:
Jowillianto
2025-02-03 19:27:10 +01:00
committed by GitHub
parent f4c7435516
commit 6d51c12db5
142 changed files with 1087 additions and 1240 deletions
+4 -4
View File
@@ -17,14 +17,14 @@ template <internal::StringLiteral field_name_>
struct AddStructName {
/// Adds the name of the struct as a new field.
template <class StructType>
static auto process(auto&& _view) {
static auto process(const auto& _view) {
using LiteralType = Literal<
internal::remove_namespaces<internal::get_type_name<StructType>()>()>;
using FieldType = Field<field_name_, LiteralType>;
const auto add_new_field = [](auto&&... _fields) {
return make_named_tuple(FieldType(LiteralType()), std::move(_fields)...);
const auto add_new_field = [](const auto&... _fields) {
return make_named_tuple(FieldType(LiteralType()), _fields...);
};
return rfl::apply(add_new_field, std::move(_view.fields()));
return rfl::apply(add_new_field, _view.fields());
}
};