[webkit-changes] [WebKit/WebKit] 9d59d5: invokeAsync should let you call method returning E...

Jean-Yves Avenard noreply at github.com
Tue Nov 21 04:44:44 PST 2023


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 9d59d5e948151feea0c46bcf270aff3ba4aba62e
      https://github.com/WebKit/WebKit/commit/9d59d5e948151feea0c46bcf270aff3ba4aba62e
  Author: Jean-Yves Avenard <jya at apple.com>
  Date:   2023-11-21 (Tue, 21 Nov 2023)

  Changed paths:
    M Source/WTF/wtf/NativePromise.h
    M Source/WTF/wtf/TypeTraits.h
    M Tools/TestWebKitAPI/Tests/WTF/NativePromise.cpp

  Log Message:
  -----------
  invokeAsync should let you call method returning Expected<T, U>
https://bugs.webkit.org/show_bug.cgi?id=265175
rdar://118671806

Reviewed by Youenn Fablet.

Add createSettledPromise(Expected&&> utility method.

Add API tests.

* Source/WTF/wtf/NativePromise.h:
(WTF::createSettledPromise):
(WTF::invokeAsync):
* Source/WTF/wtf/TypeTraits.h: Add IsExpected template.
* Tools/TestWebKitAPI/Tests/WTF/NativePromise.cpp:
(TestWebKitAPI::TEST):

Canonical link: https://commits.webkit.org/271010@main




More information about the webkit-changes mailing list