From 4ae416f06a461776f9e4b2aecbdd1d66f89673d1 Mon Sep 17 00:00:00 2001 From: Howard Hinnant Date: Thu, 27 Jul 2017 14:34:11 -0400 Subject: [PATCH] Add default constructor for weekday_indexed * This enables the year_month_weekday default constructor. --- date.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/date.h b/date.h index c753b29..7a2a008 100644 --- a/date.h +++ b/date.h @@ -418,6 +418,7 @@ class weekday_indexed unsigned char index_ : 4; public: + weekday_indexed() = default; CONSTCD11 weekday_indexed(const date::weekday& wd, unsigned index) NOEXCEPT; CONSTCD11 date::weekday weekday() const NOEXCEPT; @@ -6099,6 +6100,8 @@ from_stream(std::basic_istream& is, const CharT* fmt, { if (wd == 7) wd = 0; + else if (wd == 0) + wd = 7; } } else if (modified == CharT{'O'})