Namespaces
Variants

std::chrono:: operator<< (std::chrono::weekday_indexed)

From cppreference.net
헤더 파일에 정의됨 <chrono>
template < class CharT, class Traits >

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

const std:: chrono :: weekday_indexed & wdi ) ;
(C++20부터)

wdi 의 텍스트 표현을 os 스트림으로 출력합니다. 마치 다음과 같이:

if ( wdi. index ( ) >= 1 && wdi. index ( ) <= 5 )
os << std:: format ( os. getloc ( ) , STATICALLY_WIDEN < CharT > ( "{:L}[{}]" ) ,
wdi. weekday ( ) , wdi. index ( ) ) ;
else
os << std:: format ( os. getloc ( ) , STATICALLY_WIDEN < CharT > ( "{:L}[{} is not a valid index]" ) ,
wdi. weekday ( ) , wdi. index ( ) ) ;

여기서 STATICALLY_WIDEN < CharT > ( "..." ) "..." 입니다, 만약 CharT char 인 경우, 그리고 L "..." 입니다, 만약 CharT wchar_t 인 경우.

반환값

os

결함 보고서

다음의 동작 변경 결함 보고서들은 이전에 발표된 C++ 표준에 소급 적용되었습니다.

DR 적용 대상 게시된 동작 올바른 동작
P2372R3 C++20 기본적으로 주어진 로캘이 사용됨 L 접두사가 주어진 로캘을 사용하기 위해 필요함

참고 항목

(C++20)
인수의 형식화된 표현을 새 문자열에 저장합니다
(function template)
weekday 에 대한 형식화 지원
(class template specialization)