Repository navigation
MainActor and @AppStorage bridging fixes - #301
Open
kageroumado wants to merge 4 commits into
Open
kageroumado wants to merge 4 commits into
kageroumado wants to merge 4 commits into
Conversation
A package with .defaultIsolation(MainActor.self) fails to compile the generated bridge: the private …TypeErased class becomes main-actor isolated, while toTypeErased() constructs it from a nonisolated context. Mark the class nonisolated; modules with nonisolated default isolation are unchanged. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The generated _Swift_release @_cdecl runs on the JVM finalizer daemon. Under default MainActor isolation it inherits main-actor isolation and traps on the executor check. Mark it nonisolated. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Bundle_Support.swift declares the init?(path:) and init(for:) interceptors in an extension of AndroidBundle. In a module with default MainActor isolation they become main-actor isolated, and the synthesized Bundle.module, a nonisolated static, no longer compiles: "main actor-isolated default value in a nonisolated context". Mark both nonisolated. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A generic view's type-erased peer declared Java_initState_x as () -> SkipUI.StateSupport for an @AppStorage property, while the view's own accessors produce AppStorageSupport, so the generated code did not type-check. Pick the support type the way swiftUIInitState does. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Default MainActor isolation causes generated bridges to fail compilation or trap during peer release. Generic views using
@AppStoragealso fail to compile because their type-erased peers use the wrong support type.Skip Pull Request Checklist:
REQUIRED: I have signed the Contributor Agreement
REQUIRED: I have tested my change locally with
swift testAI was used to generate or assist with generating this PR.
Claude Code assisted with the code; Codex edited this description. Reproduced and verified in a Skip Fuse app on an Android 16 emulator, in debug and release builds.