Skip to content
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

[SR-11047] DateFormatter ru_RU formatting is incorrect in Linux #3299

Closed
kirilltitov opened this issue Jun 29, 2019 · 1 comment
Closed

[SR-11047] DateFormatter ru_RU formatting is incorrect in Linux #3299

kirilltitov opened this issue Jun 29, 2019 · 1 comment

Comments

@kirilltitov
Copy link

Previous ID SR-11047
Radar None
Original Reporter @kirilltitov
Type Bug
Status Resolved
Resolution Done
Environment

Official 5.0.1 Docker image

Additional Detail from JIRA
Votes 0
Component/s Foundation
Labels Bug
Assignee None
Priority Medium

md5: eb102f30e8949b4249af8b054776b078

Issue Description:

Following snippet works correctly in macOS:

import Foundation


let formatter = DateFormatter()
formatter.dateStyle = .long
formatter.timeStyle = .short
formatter.locale = Locale(identifier: "ru_RU")


print(formatter.string(from: Date(timeIntervalSince1970: 1561846736.749614)))

displaying

30 июня 2019 г., 1:18

However, when run in Linux, it displays

июня 29, 2019 at 10:18 PM

Other locales might be affected too.

@spevans
Copy link
Collaborator

spevans commented Nov 17, 2019

This has been fixed in 5.1

$ ~/swift-5.0.1-RELEASE-ubuntu18.04/usr/bin/swift sr-11047.swift 
июня 29, 2019 at 11:18 PM

$ ~/swift-5.1-RELEASE-ubuntu18.04/usr/bin/swift sr-11047.swift 
29 июня 2019 г., 23:18
 

@swift-ci swift-ci transferred this issue from apple/swift-issues Apr 25, 2022
@shahmishal shahmishal transferred this issue from apple/swift May 5, 2022
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants