名稱空間
變體
操作

std::chrono::operator<<(std::chrono::year_month_weekday_last)

來自 cppreference.com
 
 
 
 
定義於標頭檔案 <chrono>
template< class CharT, class Traits >

std::basic_ostream<CharT, Traits>&
    operator<<( std::basic_ostream<CharT, Traits>& os,

                const std::chrono::year_month_weekday_last& ymwdl );
(C++20 起)

Outputs a textual representation of ymwdl into os, as if by

os << std::format(os.getloc(), STATICALLY_WIDEN<CharT>("{}/{:L}/{:L}"),
                  ymwdl.year(), ymwdl.month(), ymwdl.weekday_last());

where STATICALLY_WIDEN<CharT>("{}/{:L}/{:L}") is "{}/{:L}/{:L}" if CharT is char, and L"..." if CharT is wchar_t.

[edit] 返回值

os

[edit] 缺陷報告

下列更改行為的缺陷報告追溯地應用於以前出版的 C++ 標準。

缺陷報告 應用於 釋出時的行為 正確的行為
P2372R3 C++20 預設使用給定區域設定 需要 L 才能使用給定區域設定

[edit] 亦可參見

(C++20)
將引數的格式化表示儲存在新字串中
(函式模板) [編輯]
year_month_day 的格式化支援
(類模板特化) [編輯]