Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Fix some Embedded Swift issues in JavaScriptEventLoop #344

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
kateinoigakukun merged 2 commits into main from maxd/embedded-concurrency1
Apr 16, 2025

Conversation

@MaxDesiatov
Copy link
Member

@MaxDesiatov MaxDesiatov commented Apr 16, 2025

This change fixes some of the issues that appear when building this library with Embedded Swift. It adds missing concurrency imports and avoids use of throwing tasks that are not supported in Embedded Swift. Standard Swift's Result type is used instead to express error throwing.

This change fixes some of the issues that appear when building this library with Embedded Swift. It adds missing concurrency imports and avoids use of throwing tasks that are not supported in Embedded Swift. Standard Swift's `Result` type is used instead to express error throwing.
@MaxDesiatov MaxDesiatov changed the title (削除) Fix some Embedded Swift issues in JavaScriptEventLoop (削除ここまで) (追記) Fix some Embedded Swift issues in JavaScriptEventLoop (追記ここまで) Apr 16, 2025
///
/// - Note: Calling this function does not switch from the caller's isolation domain.
public func value(isolation: isolated (any Actor)? = #isolation) async throws -> JSValue {
try await withUnsafeThrowingContinuation(isolation: isolation) { [self] continuation in
Copy link
Member

@kateinoigakukun kateinoigakukun Apr 16, 2025

Choose a reason for hiding this comment

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

We need a typed-throws version of withContinuation 😔

@kateinoigakukun kateinoigakukun merged commit d3b26d3 into main Apr 16, 2025
6 checks passed
@kateinoigakukun kateinoigakukun deleted the maxd/embedded-concurrency1 branch April 16, 2025 15:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@kateinoigakukun kateinoigakukun kateinoigakukun approved these changes

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

AltStyle によって変換されたページ (->オリジナル) /