Created on 2023-10-15.00:00:00 last changed 3 weeks ago
[ 2023-11-03; Reflector poll ]
Set priority to 4 after reflector poll. "Problem looks theoretical, all entry points to formatters are constrained."
[format.formatter.spec]/2 requires some std::formatter specializations are only enabled for character types char and wchar_t. But for specializations that are explicitly shown in the synopses ([format.syn], [time.syn], and [thread.thread.id]), there is no such restrictions for charT. The difference may be observable via the std::formattable concept, e.g. std::formattable<std::chrono::second, char8_t> is currently satisfied, even though there would be a hard error during formatting due to STATICALLY-WIDEN.Perhaps we should introduce an exposition-only concept that is only satisfied (and modeled) by char and wchar_t for now, and constrain the charT template parameter of all std::formatter specializations that are explicitly mentioned in synopses with that concept. This is what libc++ currently implements (e.g. the __fmt_char_type concept and its usage in <chrono>).
|2023-11-03 18:08:28||admin||set||messages: + msg13810|