Skip to content

Async catching Result initializer - #3234

Merged
DougGregor merged 5 commits into
swiftlang:mainfrom
mattmassicotte:async-result-support
Apr 29, 2026
Merged

Async catching Result initializer#3234
DougGregor merged 5 commits into
swiftlang:mainfrom
mattmassicotte:async-result-support

Conversation

@mattmassicotte

@mattmassicotte mattmassicotte commented Apr 8, 2026

Copy link
Copy Markdown
Contributor

This is a single addition to the standard library. It adds an asynchronous version of Result(catching:).

@Frizlab

Frizlab commented Apr 8, 2026

Copy link
Copy Markdown

I always write this extension; it would be great to have this as a part of the language!

Comment thread proposals/0NNN-async-result-support.md Outdated

@ktoso ktoso left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks for reviving this proposal :)

@rjmccall rjmccall added LSG Contains topics under the domain of the Language Steering Group new proposal Adds a new proposal document labels Apr 16, 2026
@mattmassicotte mattmassicotte changed the title Initial idea for async Result support Async catching Result initializer Apr 22, 2026
@mattmassicotte
mattmassicotte marked this pull request as ready for review April 22, 2026 15:53
@mattmassicotte

Copy link
Copy Markdown
Contributor Author

The compiler PR for this is now reviewable, so I think this is now ready for the next stage.

@DougGregor
DougGregor merged commit 329fe5c into swiftlang:main Apr 29, 2026
ktoso added a commit to swiftlang/swift that referenced this pull request Jun 1, 2026
- **Explanation**:

Implementation of an async catching initializer for Result as part of
swiftlang/swift-evolution#3234

- **Scope**:

Details in proposal.

- **Issues**:

- **Original PRs**:

- **Risk**:

- **Testing**:

I've added two tests to cover some of functionality that was being
exercised for the synchronous cases. It seems sufficient to me, but I'd
like feedback on this.

- **Reviewers**:

Would love for @ktoso to have a peek before finalizing.

---------

Co-authored-by: Jamie <2119834+jamieQ@users.noreply.github.com>
Co-authored-by: Konrad `ktoso` Malawski <konrad.malawski@project13.pl>
Co-authored-by: Ben Rimmington <me@benrimmington.com>
Co-authored-by: Konrad Malawski <ktoso@apple.com>
Teemperor pushed a commit to Teemperor/swift-mono that referenced this pull request Jun 1, 2026
- **Explanation**:

Implementation of an async catching initializer for Result as part of
swiftlang/swift-evolution#3234

- **Scope**:

Details in proposal.

- **Issues**:

- **Original PRs**:

- **Risk**:

- **Testing**:

I've added two tests to cover some of functionality that was being
exercised for the synchronous cases. It seems sufficient to me, but I'd
like feedback on this.

- **Reviewers**:

Would love for @ktoso to have a peek before finalizing.

---------

Co-authored-by: Jamie <2119834+jamieQ@users.noreply.github.com>
Co-authored-by: Konrad `ktoso` Malawski <konrad.malawski@project13.pl>
Co-authored-by: Ben Rimmington <me@benrimmington.com>
Co-authored-by: Konrad Malawski <ktoso@apple.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

LSG Contains topics under the domain of the Language Steering Group new proposal Adds a new proposal document

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants