Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit7e1e39c

Browse files
authored
Bump temporal_rs to v0.1.2 (#4530)
<!---Thank you for contributing to Boa! Please fill out the template below,and remove or add anyinformation as you feel necessary.--->This Pull Request bumps to the latest release of temporal_rs and addshandling for a small temporal_rs bug that fixes the remainingPlainYearMonth tests.
1 parente6110c7 commit7e1e39c

File tree

3 files changed

+12
-7
lines changed

3 files changed

+12
-7
lines changed

‎Cargo.lock‎

Lines changed: 4 additions & 4 deletions
Some generated files are not rendered by default. Learn more aboutcustomizing how changed files appear on GitHub.

‎Cargo.toml‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -123,8 +123,8 @@ intrusive-collections = "0.9.7"
123123
cfg-if ="1.0.4"
124124
either ="1.15.0"
125125
sys-locale ="0.3.2"
126-
timezone_provider = {version ="0.1.0" }
127-
temporal_rs = {version ="0.1.1",default-features =false }
126+
timezone_provider = {version ="0.1.2" }
127+
temporal_rs = {version ="0.1.2",default-features =false }
128128
web-time ="1.1.0"
129129
criterion ="0.7.0"
130130
float-cmp ="0.10.0"

‎core/engine/src/builtins/temporal/plain_year_month/mod.rs‎

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -561,10 +561,15 @@ impl PlainYearMonth {
561561
};
562562
// 4. Let calendar be yearMonth.[[Calendar]].
563563
// 5. Let fields be ISODateToFields(calendar, yearMonth.[[ISODate]], year-month).
564-
// TODO: We may need to throw early on an empty partial for Order of operations, but ideally this is enforced by `temporal_rs`
565564
// 6. Let partialYearMonth be ? PrepareCalendarFields(calendar, temporalYearMonthLike, « year, month, month-code », « », partial).
566565
// 7. Set fields to CalendarMergeFields(calendar, fields, partialYearMonth).
567566
let fields =to_year_month_calendar_fields(&obj, year_month.inner.calendar(), context)?;
567+
// NOTE: Update temporal_rs to handle this.
568+
if fields.is_empty(){
569+
returnErr(JsNativeError::typ()
570+
.with_message("temporalYearMonthLike cannot be an empty object")
571+
.into());
572+
}
568573
// 8. Let resolvedOptions be ? GetOptionsObject(options).
569574
let resolved_options =get_options_object(args.get_or_undefined(1))?;
570575
// 9. Let overflow be ? GetTemporalOverflowOption(resolvedOptions).

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp