@@ -87,7 +87,6 @@ concept OnlyNoneModifiers = (... && (Other == TypeModifier::None));
87
87
template <typename Type, TypeModifier... Other>
88
88
concept InputVariableUniquePtr = InputVariableClass<Type> && OnlyNoneModifiers<Other...>;
89
89
90
-
91
90
// Serialize variable input values with chained type modifiers which add nullable or list wrappers.
92
91
template <typename Type>
93
92
struct ModifiedVariable
@@ -115,7 +114,7 @@ struct ModifiedVariable
115
114
116
115
// Peel off the none modifier. If it's included, it should always be last in the list.
117
116
template <TypeModifier Modifier = TypeModifier::None, TypeModifier... Other>
118
- [[nodiscard]] static
117
+ [[nodiscard]] static inline
119
118
typename std::enable_if_t <TypeModifier::None == Modifier && sizeof ...(Other) == 0 ,
120
119
response::Value>
121
120
serialize (Type&& value)
@@ -126,7 +125,7 @@ struct ModifiedVariable
126
125
127
126
// Peel off nullable modifiers.
128
127
template <TypeModifier Modifier, TypeModifier... Other>
129
- [[nodiscard]] static
128
+ [[nodiscard]] static inline
130
129
typename std::enable_if_t <TypeModifier::Nullable == Modifier, response::Value>
131
130
serialize (typename VariableTraits<Type, Modifier, Other...>::type&& nullableValue)
132
131
{
@@ -143,8 +142,9 @@ struct ModifiedVariable
143
142
144
143
// Peel off list modifiers.
145
144
template <TypeModifier Modifier, TypeModifier... Other>
146
- [[nodiscard]] static typename std::enable_if_t <TypeModifier::List == Modifier, response::Value>
147
- serialize (typename VariableTraits<Type, Modifier, Other...>::type&& listValue)
145
+ [[nodiscard]] static inline
146
+ typename std::enable_if_t <TypeModifier::List == Modifier, response::Value>
147
+ serialize (typename VariableTraits<Type, Modifier, Other...>::type&& listValue)
148
148
{
149
149
response::Value result { response::Type::List };
150
150
@@ -159,7 +159,7 @@ struct ModifiedVariable
159
159
160
160
// Peel off the none modifier. If it's included, it should always be last in the list.
161
161
template <TypeModifier Modifier = TypeModifier::None, TypeModifier... Other>
162
- [[nodiscard]] static
162
+ [[nodiscard]] static inline
163
163
typename std::enable_if_t <TypeModifier::None == Modifier && sizeof ...(Other) == 0 , Type>
164
164
duplicate (const Type& value)
165
165
{
@@ -169,7 +169,7 @@ struct ModifiedVariable
169
169
170
170
// Peel off nullable modifiers.
171
171
template <TypeModifier Modifier, TypeModifier... Other>
172
- [[nodiscard]] static typename std::enable_if_t <TypeModifier::Nullable == Modifier,
172
+ [[nodiscard]] static inline typename std::enable_if_t <TypeModifier::Nullable == Modifier,
173
173
typename VariableTraits<Type, Modifier, Other...>::type>
174
174
duplicate (const typename VariableTraits<Type, Modifier, Other...>::type& nullableValue)
175
175
{
@@ -193,7 +193,7 @@ struct ModifiedVariable
193
193
194
194
// Peel off list modifiers.
195
195
template <TypeModifier Modifier, TypeModifier... Other>
196
- [[nodiscard]] static typename std::enable_if_t <TypeModifier::List == Modifier,
196
+ [[nodiscard]] static inline typename std::enable_if_t <TypeModifier::List == Modifier,
197
197
typename VariableTraits<Type, Modifier, Other...>::type>
198
198
duplicate (const typename VariableTraits<Type, Modifier, Other...>::type& listValue)
199
199
{
@@ -259,7 +259,7 @@ struct ModifiedResponse
259
259
260
260
// Peel off the none modifier. If it's included, it should always be last in the list.
261
261
template <TypeModifier Modifier = TypeModifier::None, TypeModifier... Other>
262
- [[nodiscard]] static
262
+ [[nodiscard]] static inline
263
263
typename std::enable_if_t <TypeModifier::None == Modifier && sizeof ...(Other) == 0 , Type>
264
264
parse (response::Value&& response)
265
265
{
@@ -268,7 +268,7 @@ struct ModifiedResponse
268
268
269
269
// Peel off nullable modifiers.
270
270
template <TypeModifier Modifier, TypeModifier... Other>
271
- [[nodiscard]] static typename std::enable_if_t <TypeModifier::Nullable == Modifier,
271
+ [[nodiscard]] static inline typename std::enable_if_t <TypeModifier::Nullable == Modifier,
272
272
std::optional<typename ResponseTraits<Type, Other...>::type>>
273
273
parse (response::Value&& response)
274
274
{
@@ -283,7 +283,7 @@ struct ModifiedResponse
283
283
284
284
// Peel off list modifiers.
285
285
template <TypeModifier Modifier, TypeModifier... Other>
286
- [[nodiscard]] static typename std::enable_if_t <TypeModifier::List == Modifier,
286
+ [[nodiscard]] static inline typename std::enable_if_t <TypeModifier::List == Modifier,
287
287
std::vector<typename ResponseTraits<Type, Other...>::type>>
288
288
parse (response::Value&& response)
289
289
{
0 commit comments