-
Notifications
You must be signed in to change notification settings - Fork 533
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
Add parse_from_* to DateTime #278
Conversation
Adds conversion to/from Utc, Local, and FixedOffset. Originally planned to go through NaiveDateTime, but it seems that is not necessary?
Documentation added to both `impl`s and functions so that they are visible to both users perusing the online documentation and in autocomplete/intellisense engines.
As discussed in chronotope#263. Note that this breaks existing code that did not explicitly specify the offset in calls to `DateTime::parse_from_*`, as they are now ambiguous. Relies on chronotope#271 for conversion back into `DateTime<Utc>` from `DateTime<FixedOffset>` as the latter is used under the hood.
@quodlibetor I don't know if you want to take this alongside #271 as both feature ergonomic improvements to working with timezoned |
Nope, just deleted the master branch in response to user confusion. |
Ah ok. Do you mind reopening the issue? or do you need me to create a new pr with this rebased against main? |
I tried, but was unable to reopen the PR. If you're still interested, please rebase on main. |
Re-based and resubmitted as #806. |
As discussed in #263. Note that this breaks existing code that did not
explicitly specify the offset in calls to
DateTime::parse_from_*
, asthey are now ambiguous.
Relies on #271 for conversion back into
DateTime<Utc>
fromDateTime<FixedOffset>
as the latter is used under the hood.