Avatar
@swift-6.0.3 -swift-version 6 enum Foo { @MainActor private(set) static var bar = "" } extension Foo { @MainActor static func setup(bar: String) { Self.bar = bar } } func foo() { print(Foo.bar) } foo() (edited)