Skip to content

Commit bcc44f2

Browse files
authored
CalendarGregorian search functions may loop indefinitely when reaching the capped date (swiftlang#423)
* CalendarGregorian search functions may loop indefinitely when reaching the capped date We are capping the input `Date` to the internal upper bound in various internal functions. This caused the incremental search functions to loop indefinitely because the search results are always the same since the effective input never changes. Remove the capping from internal functions entirely. The capping was added to improving performance when calling into ICU. We should instead move the capping up to Calendar.swift, the call site to reach consistent behavior, but not inside the implementation. Also fix miscellaneous other problems found in testing Resolves 122946218 * enable compatibility tests for CI to run * Address review feedback * Remove incorrect assumption -- we should not store locale's prefs as the calendar's custom first day because it may be copied accidentally
1 parent b8ef4ce commit bcc44f2

File tree

5 files changed

+973
-121
lines changed

5 files changed

+973
-121
lines changed

0 commit comments

Comments
 (0)