Skip to content

Commit 4d81e27

Browse files
Fix doc typo on yearForWeekOfYear case in DateComponents
1 parent 88768b5 commit 4d81e27

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Darwin/Foundation-swiftoverlay/DateComponents.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -178,7 +178,7 @@ public struct DateComponents : ReferenceConvertible, Hashable, Equatable, _Mutab
178178

179179
/// The ISO 8601 week-numbering year of the receiver.
180180
///
181-
/// The Gregorian calendar defines a week to have 7 days, and a year to have 356 days, or 366 in a leap year. However, neither 356 or 366 divide evenly into a 7 day week, so it is often the case that the last week of a year ends on a day in the next year, and the first week of a year begins in the preceding year. To reconcile this, ISO 8601 defines a week-numbering year, consisting of either 52 or 53 full weeks (364 or 371 days), such that the first week of a year is designated to be the week containing the first Thursday of the year.
181+
/// The Gregorian calendar defines a week to have 7 days, and a year to have 365 days, or 366 in a leap year. However, neither 365 or 366 divide evenly into a 7 day week, so it is often the case that the last week of a year ends on a day in the next year, and the first week of a year begins in the preceding year. To reconcile this, ISO 8601 defines a week-numbering year, consisting of either 52 or 53 full weeks (364 or 371 days), such that the first week of a year is designated to be the week containing the first Thursday of the year.
182182
///
183183
/// You can use the yearForWeekOfYear property with the weekOfYear and weekday properties to get the date corresponding to a particular weekday of a given week of a year. For example, the 6th day of the 53rd week of the year 2005 (ISO 2005-W53-6) corresponds to Sat 1 January 2005 on the Gregorian calendar.
184184
/// - note: This value is interpreted in the context of the calendar in which it is used.

0 commit comments

Comments
 (0)