-
Notifications
You must be signed in to change notification settings - Fork 113
remove requirment on macOS 10.13 #156
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
Conversation
closes #152 |
note |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @tomerd, I've thought about this a little more... Since strptime
is not available through Glibc, we use this really only for macOS before 10.13
. In the Swift.package
we define the minimum Swift version though with 5.2
. I doubt that there is any macOS version out there with 10.12
that runs Swift 5.2, not to speak of a current Xcode version that runs on macOS 10.12
or below, which is the only use case for this.
So maybe we should just preconditionFailure
if we are below 10.13
? wdyt? Sorry for coming up with this now, after you've already implemented it.
that sounds okay to me too. @helje5 wdyt? |
Either is fine for me. There are some Mac users which tend to stick to older versions, but they are probably not Swift target audience in the first place ;-) |
The really interesting question here is why spm decided to stick to 10.10 still, that feels a little weird, but the same reasoning should be applied i guess |
@fabianfett what is your concern about taking this as-is? code bloat/complexity? |
@tomerd I came to the conclusion, when I thought about, how we could test this... Date conversions should be tested by a unit test imho. When thinking about it, I wasn’t sure if there is actually a machine that could fulfill the requirements to run this branch. If there is no machine that the code could be ever run on, we shouldn’t add it because it increases complexity. |
motivation: simplify downstream libraries changes: use custom ISO8601 decoders on macOS < 10.13
@fabianfett addressed |
#if os(Linux) | ||
import Glibc | ||
#else | ||
import Darwin.C | ||
#endif | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@tomerd leftover?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
good catch, removed
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @tomerd LGTM
motivation: simplify downstream libraries
changes: use custom ISO8601 decoders on macOS < 10.13