Skip to content

Add Time#rfc3339 and Time.rfc3339#59

Merged
jeremyevans merged 1 commit into
ruby:masterfrom
jeremyevans:rfc3339
Jul 19, 2026
Merged

Add Time#rfc3339 and Time.rfc3339#59
jeremyevans merged 1 commit into
ruby:masterfrom
jeremyevans:rfc3339

Conversation

@jeremyevans

Copy link
Copy Markdown
Contributor

This allows easier transition of code using DateTime to using Time.

Time#rfc3339 is an alias to #xmlschema and is just for consistency.

Time.rfc3339 is similar to Time.xmlschema, but allows a space between the date and time, while Time.xmlschema does not (it requires a "T").

Introduce a Time._xmlschema private method so that Time.xmlschema and Time.rfc3339 can share most of the implementation.

This allows easier transition of code using DateTime to using Time.

Time#rfc3339 is an alias to #xmlschema and is just for consistency.

Time.rfc3339 is similar to Time.xmlschema, but allows a space
between the date and time, while Time.xmlschema does not (it
requires a "T").

Introduce a Time._xmlschema private method so that Time.xmlschema
and Time.rfc3339 can share most of the implementation.
@jeremyevans
jeremyevans requested a review from akr June 8, 2026 21:10
@jeremyevans
jeremyevans merged commit 9bca339 into ruby:master Jul 19, 2026
19 checks passed
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