diff --git a/include/fmt/std.h b/include/fmt/std.h index 33993f7f1038..dbeb4046a0fa 100644 --- a/include/fmt/std.h +++ b/include/fmt/std.h @@ -263,10 +263,9 @@ auto write_expected_alternative(OutputIt out, const T& v) -> OutputIt { FMT_EXPORT template -struct formatter< - std::expected, Char, - std::enable_if_t, is_formattable>>> { +struct formatter, Char, + std::enable_if_t, is_formattable>>> { template FMT_CONSTEXPR auto parse(ParseContext& ctx) -> decltype(ctx.begin()) { return ctx.begin(); @@ -277,12 +276,12 @@ struct formatter< -> decltype(ctx.out()) { auto out = ctx.out(); - if(value.has_value()) { + if (value.has_value()) { out = detail::write(out, "expected("); - out = detail::write_expected_alternative(out, value.value()); + out = detail::write_expected_alternative(out, value.value()); } else { out = detail::write(out, "unexpected("); - out = detail::write_expected_alternative(out, value.error()); + out = detail::write_expected_alternative(out, value.error()); } *out++ = ')'; return out;