Skip to content

Commit

Permalink
const qualify format function for systen_clock
Browse files Browse the repository at this point in the history
  • Loading branch information
vitaut authored and PoetaKodu committed Nov 11, 2021
1 parent bf1977d commit 1fdad8a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion include/fmt/chrono.h
Original file line number Diff line number Diff line change
Expand Up @@ -1782,7 +1782,7 @@ struct formatter<std::chrono::time_point<std::chrono::system_clock, Duration>,

template <typename FormatContext>
auto format(std::chrono::time_point<std::chrono::system_clock> val,
FormatContext& ctx) -> decltype(ctx.out()) {
FormatContext& ctx) const -> decltype(ctx.out()) {
return formatter<std::tm, Char>::format(localtime(val), ctx);
}

Expand Down

0 comments on commit 1fdad8a

Please sign in to comment.