Skip to content

Fixed wrong statement about thread safety of formatters#128

Open
valeriyvan wants to merge 1 commit intoobjcio:masterfrom
valeriyvan:patch-2
Open

Fixed wrong statement about thread safety of formatters#128
valeriyvan wants to merge 1 commit intoobjcio:masterfrom
valeriyvan:patch-2

Conversation

@valeriyvan
Copy link
Member

Fixed wrong statement about thread safety of NSDateFormatter and NSNumberFormatter

Fixed wrong statement about thread safety of NSDateFormatter and NSNumberFormatter
@chriseidhof
Copy link
Contributor

Hm, great point. But I think it's slightly more complicated even. Even if the properties themselves have atomic getters and setters, the fact that the object is mutable at all makes it unsafe for multi-threaded programming... I'm not sure what's the best way to word this.

@valeriyvan
Copy link
Member Author

I just cited Apple docs in footnote. May be it does make sense add a ref to Apple docs in footnote as well.

@valeriyvan
Copy link
Member Author

If Apple states these are thread safe in iOS 7+, I believe them. It's interesting how they achieved that. Lock free structures? Good question to ask in labs in WWDC.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants