Branch: refs/heads/main Home: https://github.com/WebKit/WebKit Commit: 1d296b968d89cb37715dd09be81e31f270afeb28 https://github.com/WebKit/WebKit/commit/1d296b968d89cb37715dd09be81e31f270afeb28 Author: Sosuke Suzuki <aosuk...@gmail.com> Date: 2025-06-20 (Fri, 20 Jun 2025)
Changed paths: A JSTests/stress/to-integer-or-infinity-trunc-negative-fractional.js M JSTests/test262/expectations.yaml M Source/JavaScriptCore/dfg/DFGAbstractInterpreterInlines.h M Source/JavaScriptCore/dfg/DFGOperations.cpp M Source/JavaScriptCore/runtime/JSCJSValueInlines.h Log Message: ----------- [JSC] `toIntegerOrInfinity` should trunc a negative fractional to `+0.0` https://bugs.webkit.org/show_bug.cgi?id=294734 Reviewed by Ross Kirsling. According to the specification, `ToIntegerOrInfinity` should truncate negative fractional values to `+0.0`[1]. However, the current JSC implementation truncates them to `-0.0`, which may cause errors in some operations. Therefore, this patch changes `ToIntegerOrInfinity` to truncate negative fractional values to `+0.0`. [1]: https://tc39.es/ecma262/#sec-tointegerorinfinity * JSTests/stress/to-integer-or-infinity-tranc-negative-fractional.js: Added. (shouldBe): * JSTests/test262/expectations.yaml: * Source/JavaScriptCore/dfg/DFGAbstractInterpreterInlines.h: (JSC::DFG::AbstractInterpreter<AbstractStateType>::executeEffects): * Source/JavaScriptCore/dfg/DFGOperations.cpp: (JSC::DFG::JSC_DEFINE_NOEXCEPT_JIT_OPERATION): * Source/JavaScriptCore/runtime/JSCJSValueInlines.h: (JSC::JSValue::toIntegerOrInfinity const): Canonical link: https://commits.webkit.org/296468@main To unsubscribe from these emails, change your notification settings at https://github.com/WebKit/WebKit/settings/notifications _______________________________________________ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes