Skip to content

feat(intl): implement Temporal.Instant.prototype.toLocaleString#5096

Open
JkrishnaD wants to merge 1 commit intoboa-dev:mainfrom
JkrishnaD:feat/temporal-instant-tolocalestring
Open

feat(intl): implement Temporal.Instant.prototype.toLocaleString#5096
JkrishnaD wants to merge 1 commit intoboa-dev:mainfrom
JkrishnaD:feat/temporal-instant-tolocalestring

Conversation

@JkrishnaD
Copy link
Contributor

This Pull Request fixes/closes #5087.

It changes the following:

  • Implements steps 1 & 2 of the spec: validates this is a Temporal.Instant objectScreenshot 2026-03-15 at 1 38 23 PM
  • Accepts locales and options arguments (previously ignored with _)
  • Falls back to to_ixdtf_string_with_provider until Intl.DateTimeFormat integration is complete
  • Removes the vague TODO: Update for ECMA-402 compliance comment.

Full Intl.DateTimeFormat integration (steps 3 & 4) is blocked on #5080, which adds format_date_time_locale and FormatDefaults::All. Once that merges, this can be updated to use that function directly.

Spec: https://tc39.es/proposal-temporal/#sec-temporal.instant.tolocalestring

@github-actions github-actions bot added the Waiting On Review Waiting on reviews from the maintainers label Mar 15, 2026
@github-actions github-actions bot added this to the v1.0.0 milestone Mar 15, 2026
@github-actions github-actions bot added the C-Builtins PRs and Issues related to builtins/intrinsics label Mar 15, 2026
@github-actions
Copy link

Test262 conformance changes

Test result main count PR count difference
Total 52,963 52,963 0
Passed 50,070 50,070 0
Ignored 2,072 2,072 0
Failed 821 821 0
Panics 0 0 0
Conformance 94.54% 94.54% 0.00%

Tested main commit: 3016f492d02a06033e11269fdcef603d293222c4
Tested PR commit: ceab2130bac11923ce54e63089ddc7cca2b28c70
Compare commits: 3016f49...ceab213

@codecov
Copy link

codecov bot commented Mar 15, 2026

Codecov Report

❌ Patch coverage is 0% with 3 lines in your changes missing coverage. Please review.
✅ Project coverage is 59.10%. Comparing base (6ddc2b4) to head (ceab213).
⚠️ Report is 867 commits behind head on main.

Files with missing lines Patch % Lines
core/engine/src/builtins/temporal/instant/mod.rs 0.00% 3 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##             main    #5096       +/-   ##
===========================================
+ Coverage   47.24%   59.10%   +11.85%     
===========================================
  Files         476      563       +87     
  Lines       46892    62667    +15775     
===========================================
+ Hits        22154    37037    +14883     
- Misses      24738    25630      +892     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@JkrishnaD JkrishnaD marked this pull request as ready for review March 15, 2026 08:38
@JkrishnaD
Copy link
Contributor Author

@jedel1043 this pr is just a base and waiting for the #5080 get merged as in that we get to_locale_string which we can use directly in here

@jedel1043
Copy link
Member

jedel1043 commented Mar 16, 2026

Marking as blocked on #5080

@jedel1043 jedel1043 added Blocked Waiting for another code change and removed Waiting On Review Waiting on reviews from the maintainers labels Mar 16, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Blocked Waiting for another code change C-Builtins PRs and Issues related to builtins/intrinsics

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Implement Temporal.Instant.prototype.toLocaleString

2 participants