Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 7f38ebbabf35e067114a9ccdd56103132c880b4f
      
https://github.com/WebKit/WebKit/commit/7f38ebbabf35e067114a9ccdd56103132c880b4f
  Author: Yusuke Suzuki <[email protected]>
  Date:   2026-08-17 (Mon, 17 Aug 2026)

  Changed paths:
    M JSTests/test262/expectations.yaml
    M Source/JavaScriptCore/CMakeLists.txt
    M Source/JavaScriptCore/DerivedSources-input.xcfilelist
    M Source/JavaScriptCore/DerivedSources.make
    M Source/JavaScriptCore/JavaScriptCore.xcodeproj/project.pbxproj
    M Source/JavaScriptCore/builtins/BuiltinNames.h
    M Source/JavaScriptCore/builtins/PromiseConstructor.js
    R Source/JavaScriptCore/builtins/PromiseOperations.js
    M Source/JavaScriptCore/bytecode/LinkTimeConstant.h
    M Source/JavaScriptCore/runtime/JSGlobalObject.cpp

  Log Message:
  -----------
  [JSC] Apply Promise.try spec
change
https://bugs.webkit.org/show_bug.cgi?id=321890
rdar://185064567

Reviewed by Sosuke Suzuki.

Test262 is updated[1] to include the latest spec change proposal
for Promise.try[2], which uses PromiseResolve instead of a promise
created by NewPromiseCapability. This simplifies our Promise.try
implementation since we can just use @promiseResolve and @promiseReject
helpers instead. Also this removes the reference to
@newPromiseCapability in JSC code. So we drop PromiseOperations.js and
its JS builtins, and replace @newPromiseCapability with C++ version for
remaining WebCore users.

WebCore users can be replaced by using normal Promise + first-resolving
handler. This is fixed in a subsequent change.

[1]: https://github.com/tc39/test262/pull/5072
[2]: https://github.com/tc39/ecma262/pull/3883

* JSTests/test262/expectations.yaml:
* Source/JavaScriptCore/CMakeLists.txt:
* Source/JavaScriptCore/DerivedSources-input.xcfilelist:
*
Source/JavaScriptCore/DerivedSources.make:
* Source/JavaScriptCore/JavaScriptCore.xcodeproj/project.pbxproj:
* Source/JavaScriptCore/builtins/BuiltinNames.h:
* Source/JavaScriptCore/builtins/PromiseConstructor.js:
(try):
* Source/JavaScriptCore/builtins/PromiseOperations.js: Removed.
* Source/JavaScriptCore/bytecode/LinkTimeConstant.h:
* Source/JavaScriptCore/runtime/JSGlobalObject.cpp:
(JSC::JSC_DEFINE_HOST_FUNCTION):
(JSC::JSGlobalObject::init):

Canonical link: 
https://flagged.apple.com:443/proxy?t2=Dp6w1T7ty2&o=aHR0cHM6Ly9jb21taXRzLndlYmtpdC5vcmcvMzE5Mjc2QG1haW4=&emid=a8a7e9ff-446b-487e-b236-0c73f2cc2c71&c=11



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications

Reply via email to