85 case FormatType::Signed32:
86 if constexpr (!Config::enable_integer)
88 return ErrorCode::STATE_ERR;
90 return DispatchSignedField<int32_t>();
91 case FormatType::Signed64:
92 if constexpr (!Config::enable_integer || !Config::enable_integer_64bit)
94 return ErrorCode::STATE_ERR;
96 return DispatchSignedField<int64_t>();
97 case FormatType::Unsigned32:
98 if constexpr (!Config::enable_integer)
100 return ErrorCode::STATE_ERR;
102 return DispatchUnsignedField<FormatType::Unsigned32, uint32_t>();
103 case FormatType::Unsigned64:
104 if constexpr (!Config::enable_integer || !Config::enable_integer_64bit)
106 return ErrorCode::STATE_ERR;
108 return DispatchUnsignedField<FormatType::Unsigned64, uint64_t>();
109 case FormatType::Binary32:
110 if constexpr (!Config::enable_integer || !Config::enable_integer_base8_16)
112 return ErrorCode::STATE_ERR;
114 return DispatchUnsignedField<FormatType::Binary32, uint32_t>();
115 case FormatType::Binary64:
116 if constexpr (!Config::enable_integer || !Config::enable_integer_base8_16 ||
117 !Config::enable_integer_64bit)
119 return ErrorCode::STATE_ERR;
121 return DispatchUnsignedField<FormatType::Binary64, uint64_t>();
122 case FormatType::Octal32:
123 if constexpr (!Config::enable_integer || !Config::enable_integer_base8_16)
125 return ErrorCode::STATE_ERR;
127 return DispatchUnsignedField<FormatType::Octal32, uint32_t>();
128 case FormatType::Octal64:
129 if constexpr (!Config::enable_integer || !Config::enable_integer_base8_16 ||
130 !Config::enable_integer_64bit)
132 return ErrorCode::STATE_ERR;
134 return DispatchUnsignedField<FormatType::Octal64, uint64_t>();
135 case FormatType::HexLower32:
136 if constexpr (!Config::enable_integer || !Config::enable_integer_base8_16)
138 return ErrorCode::STATE_ERR;
140 return DispatchUnsignedField<FormatType::HexLower32, uint32_t>();
141 case FormatType::HexLower64:
142 if constexpr (!Config::enable_integer || !Config::enable_integer_base8_16 ||
143 !Config::enable_integer_64bit)
145 return ErrorCode::STATE_ERR;
147 return DispatchUnsignedField<FormatType::HexLower64, uint64_t>();
148 case FormatType::HexUpper32:
149 if constexpr (!Config::enable_integer || !Config::enable_integer_base8_16)
151 return ErrorCode::STATE_ERR;
153 return DispatchUnsignedField<FormatType::HexUpper32, uint32_t>();
154 case FormatType::HexUpper64:
155 if constexpr (!Config::enable_integer || !Config::enable_integer_base8_16 ||
156 !Config::enable_integer_64bit)
158 return ErrorCode::STATE_ERR;
160 return DispatchUnsignedField<FormatType::HexUpper64, uint64_t>();
161 case FormatType::Pointer:
162 if constexpr (!Config::enable_pointer)
164 return ErrorCode::STATE_ERR;
166 return DispatchPointerField();
167 case FormatType::Character:
168 if constexpr (!Config::enable_text)
170 return ErrorCode::STATE_ERR;
172 return DispatchCharacterField();
173 case FormatType::String:
174 if constexpr (!Config::enable_text)
176 return ErrorCode::STATE_ERR;
178 return DispatchStringField();
179 case FormatType::FloatFixed:
180 if constexpr (!FloatEnabled(FormatType::FloatFixed))
182 return ErrorCode::STATE_ERR;
184 return DispatchFloatField<FormatType::FloatFixed, float>();
185 case FormatType::DoubleFixed:
186 if constexpr (!FloatEnabled(FormatType::DoubleFixed))
188 return ErrorCode::STATE_ERR;
190 return DispatchFloatField<FormatType::DoubleFixed, double>();
191 case FormatType::FloatScientific:
192 if constexpr (!FloatEnabled(FormatType::FloatScientific))
194 return ErrorCode::STATE_ERR;
196 return DispatchFloatField<FormatType::FloatScientific, float>();
197 case FormatType::DoubleScientific:
198 if constexpr (!FloatEnabled(FormatType::DoubleScientific))
200 return ErrorCode::STATE_ERR;
202 return DispatchFloatField<FormatType::DoubleScientific, double>();
203 case FormatType::FloatGeneral:
204 if constexpr (!FloatEnabled(FormatType::FloatGeneral))
206 return ErrorCode::STATE_ERR;
208 return DispatchFloatField<FormatType::FloatGeneral, float>();
209 case FormatType::DoubleGeneral:
210 if constexpr (!FloatEnabled(FormatType::DoubleGeneral))
212 return ErrorCode::STATE_ERR;
214 return DispatchFloatField<FormatType::DoubleGeneral, double>();
215 case FormatType::LongDoubleFixed:
216 if constexpr (!FloatEnabled(FormatType::LongDoubleFixed))
218 return ErrorCode::STATE_ERR;
220 return DispatchFloatField<FormatType::LongDoubleFixed, long double>();
221 case FormatType::LongDoubleScientific:
222 if constexpr (!FloatEnabled(FormatType::LongDoubleScientific))
224 return ErrorCode::STATE_ERR;
226 return DispatchFloatField<FormatType::LongDoubleScientific, long double>();
227 case FormatType::LongDoubleGeneral:
228 if constexpr (!FloatEnabled(FormatType::LongDoubleGeneral))
230 return ErrorCode::STATE_ERR;
232 return DispatchFloatField<FormatType::LongDoubleGeneral, long double>();
233 case FormatType::TextInline:
234 case FormatType::TextRef:
235 case FormatType::TextSpace:
236 case FormatType::End:
238 return ErrorCode::STATE_ERR;