From 05e754358839afa3b002aea4b3351847740ac22e Mon Sep 17 00:00:00 2001 From: Howard Hinnant Date: Tue, 9 Jun 2020 12:46:11 -0400 Subject: [PATCH] Updated Examples and Recipes (markdown) --- Examples-and-Recipes.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Examples-and-Recipes.md b/Examples-and-Recipes.md index d98b121..958cbb9 100644 --- a/Examples-and-Recipes.md +++ b/Examples-and-Recipes.md @@ -737,7 +737,7 @@ normalize(date::year_month_day ymd) The first line simply adds 0 months to the `ymd`. If `ymd.month()` is 0, this will subtract one from the `year` and set the month to `Dec`. If `ymd.month()` is greater than 12, the year will be incremented as many times as appropriate, and the month will be brought within the proper range. This operation will do nothing if `ymd.month().ok()` is already true. -The second line will "normalize" the day field. The second line requires that the month field is already normalized. For example `2015_y/dec/32` will become `2016_y/jan/1`. If the day field is already in range, there will be no change. +The second line will "normalize" the day field. The second line requires that the month field is already normalized. For example `2015_y/December/32` will become `2016_y/January/1`. If the day field is already in range, there will be no change. The conversion from `year_month_day` to `sys_days` calls this algorithm: @@ -795,7 +795,7 @@ fifth_friday(date::year y) dates[n] = year_month_day{d}; ++n; } - if (m == dec) + if (m == December) break; } return {dates, n};