Skip to content

Remove Thai Calendar #1203

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Mar 7, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 0 additions & 10 deletions Sources/FoundationEssentials/Calendar/Calendar.swift
Original file line number Diff line number Diff line change
@@ -92,9 +92,6 @@ public struct Calendar : Hashable, Equatable, Sendable {
@available(FoundationPreview 6.2, *)
case dangi

@available(FoundationPreview 6.2, *)
case thai

@available(FoundationPreview 6.2, *)
case vietnamese

@@ -135,7 +132,6 @@ public struct Calendar : Hashable, Equatable, Sendable {
case "telugu": self = .telugu
case "vikram": self = .vikram
case "dangi": self = .dangi
case "thai": self = .thai
case "vietnamese": self = .vietnamese
default: return nil
}
@@ -169,7 +165,6 @@ public struct Calendar : Hashable, Equatable, Sendable {
case .telugu: return "telugu"
case .vikram: return "vikram"
case .dangi: return "dangi"
case .thai: return "thai"
case .vietnamese: return "vietnamese"
}
}
@@ -203,7 +198,6 @@ public struct Calendar : Hashable, Equatable, Sendable {
case .telugu: return "telugu"
case .vikram: return "vikram"
case .dangi: return "dangi"
case .thai: return "thai"
case .vietnamese: return "vietnamese"
}
}
@@ -1404,8 +1398,6 @@ public struct Calendar : Hashable, Equatable, Sendable {
return .vikram
case .dangi:
return .dangi
case .thai:
return .thai
case .vietnamese:
return .vietnamese
}
@@ -1465,8 +1457,6 @@ public struct Calendar : Hashable, Equatable, Sendable {
return .vikram
case .dangi:
return .dangi
case .thai:
return .thai
case .vietnamese:
return .vietnamese
default:
Original file line number Diff line number Diff line change
@@ -1468,8 +1468,6 @@ internal final class _CalendarICU: _CalendarProtocol, @unchecked Sendable {
return Date(timeIntervalSinceReferenceDate: -60645542400.0)
case .dangi:
fallthrough
case .thai:
fallthrough
case .vietnamese:
// TODO: This is copied from `.chinese` and needs to be revisited for each new calendar.
if time < -146325744000.0 { return nil }
@@ -1590,8 +1588,6 @@ internal final class _CalendarICU: _CalendarProtocol, @unchecked Sendable {
return DateInterval(start: Date(timeIntervalSinceReferenceDate: -60645542400.0), duration: inf_ti)
case .dangi:
fallthrough
case .thai:
fallthrough
case .vietnamese:
// TODO: This is copied from `.chinese` and needs to be revisited for each new calendar.
if time < -146325744000.0 { return nil }