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-1858] UUID should conform to RawRepresentable #4136

Open
colemancda opened this issue Jun 21, 2016 · 2 comments
Open

[SR-1858] UUID should conform to RawRepresentable #4136

colemancda opened this issue Jun 21, 2016 · 2 comments

Comments

@colemancda
Copy link
Contributor

Previous ID SR-1858
Radar None
Original Reporter @colemancda
Type Improvement
Additional Detail from JIRA
Votes 1
Component/s Foundation
Labels Improvement
Assignee None
Priority Medium

md5: c9e00ee2b3804d3159a6fa55f17bdd0c

Issue Description:

The Foundation UUID Struct should conform to RawRepresentable with String as its RawValue associated type. This will allow this type to have a deeper integration with the Swift std lib.

@belkadan
Copy link

I'm not sure String is the raw representation of UUID. Why not uuid_t?

@colemancda
Copy link
Contributor Author

Because you cannot have a fallible initializer with uuid_t. A UUID can always be converted to a String, but cannot always be initialized from a String.

init?(rawValue: String)
rawValue: String

@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
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