mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-08-01 21:59:07 +00:00
LibJS: Add parentheses around modulo operation
This is an editorial change in the Temporal spec.
See: 90e4b34
This commit is contained in:
parent
287dd03e2e
commit
aaa9524a52
Notes:
sideshowbarker
2024-07-17 10:11:41 +09:00
Author: https://github.com/linusg
Commit: aaa9524a52
Pull-request: https://github.com/SerenityOS/serenity/pull/14278
Reviewed-by: https://github.com/Dexesttp
1 changed files with 1 additions and 1 deletions
|
@ -176,7 +176,7 @@ ISOYearMonth balance_iso_year_month(double year, double month)
|
|||
// 2. Set year to year + floor((month - 1) / 12).
|
||||
year += floor((month - 1) / 12);
|
||||
|
||||
// 3. Set month to (month - 1) modulo 12 + 1.
|
||||
// 3. Set month to ((month - 1) modulo 12) + 1.
|
||||
month = modulo(month - 1, 12) + 1;
|
||||
|
||||
// 4. Return the Record { [[Year]]: year, [[Month]]: month }.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue