month_weekday_operator_ltlt
month_weekday_operator_ltlt (month_weekday 출력)
std::chrono::month_weekday에 대한 operator<<는 월과 요일(인덱스 포함)을 스트림에 출력해요.
출처: cppreference
본문
std::chrono::month_weekday의 스트림 출력 연산자는 <chrono> 헤더에 정의되어 있어요. C++20부터 사용 가능해요.
template< class CharT, class Traits >
std::basic_ostream<CharT, Traits>&
operator<<( std::basic_ostream<CharT, Traits>& os,
const std::chrono::month_weekday& mw );
mw를 스트림에 출력해요.
예제 (Example)
#include <chrono>
#include <iostream>
int main()
{
std::cout << (std::chrono::July / std::chrono::Monday[2]) << '\n'; // Jul/Mon[2]
}