-
Notifications
You must be signed in to change notification settings - Fork 3
Open
Labels
bugSomething isn't workingSomething isn't working
Description
Swift Version
6.0
Package Version
Bug Description
For this protocol
@Mocked
protocol TestProtocol: Sendable {
func something(work: @escaping @Sendable () -> Void)
}this Xcode error shows up when compiling in swift 6 mode
/var/folders/zh/vr7mqp6s529cv1tyb8y6rnt40000gn/T/swift-generated-sources/@__swiftmacro_15FetchFoundation16TestProtocolMockC9something13_MockedMethodfMp_.swift:37:13 Stored property '__something' of 'Sendable'-conforming class 'TestProtocolMock' contains non-Sendable type '() -> Void'
/var/folders/zh/vr7mqp6s529cv1tyb8y6rnt40000gn/T/swift-generated-sources/@__swiftmacro_15FetchFoundation16TestProtocolMockC9something13_MockedMethodfMp_.swift:37:13 Stored property '__something' of 'Sendable'-conforming class 'TestProtocolMock' contains non-Sendable type '(@escaping () -> Void) -> Void'
/var/folders/zh/vr7mqp6s529cv1tyb8y6rnt40000gn/T/swift-generated-sources/@__swiftmacro_15FetchFoundation16TestProtocolMockC9something13_MockedMethodfMp_.swift:37:13 Stored property '__something' of 'Sendable'-conforming class 'TestProtocolMock' contains non-Sendable type '() -> TestProtocolMock.SomethingImplementation<() -> Void>.Closure?' (aka '() -> Optional<(@escaping @Sendable () -> ()) -> ()>')
Steps to Reproduce
Turn on strict concurrency with swift 6 compiler mode
@Mocked
protocol TestProtocol: Sendable {
func something(work: @escaping @Sendable () -> Void)
}Expected Behavior
No errors
Actual Behavior
No response
Stack Trace / Logs
/var/folders/zh/vr7mqp6s529cv1tyb8y6rnt40000gn/T/swift-generated-sources/@__swiftmacro_15FetchFoundation16TestProtocolMockC9something13_MockedMethodfMp_.swift:37:13 Stored property '__something' of 'Sendable'-conforming class 'TestProtocolMock' contains non-Sendable type '() -> Void'
/var/folders/zh/vr7mqp6s529cv1tyb8y6rnt40000gn/T/swift-generated-sources/@__swiftmacro_15FetchFoundation16TestProtocolMockC9something13_MockedMethodfMp_.swift:37:13 Stored property '__something' of 'Sendable'-conforming class 'TestProtocolMock' contains non-Sendable type '(@escaping () -> Void) -> Void'
/var/folders/zh/vr7mqp6s529cv1tyb8y6rnt40000gn/T/swift-generated-sources/@__swiftmacro_15FetchFoundation16TestProtocolMockC9something13_MockedMethodfMp_.swift:37:13 Stored property '__something' of 'Sendable'-conforming class 'TestProtocolMock' contains non-Sendable type '() -> TestProtocolMock.SomethingImplementation<() -> Void>.Closure?' (aka '() -> Optional<(@escaping @Sendable () -> ()) -> ()>')Additional Context
No response
Code of Conduct
- I agree to follow this project's Code of Conduct
berbs-fetch
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working