We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent adb044e commit ec41bd6Copy full SHA for ec41bd6
Examples/Sources/ExamplePlugin/Macros.swift
@@ -91,8 +91,13 @@ public struct SendableExtensionMacro: ExtensionMacro {
91
of node: AttributeSyntax,
92
attachedTo: some DeclGroupSyntax,
93
providingExtensionsOf type: some TypeSyntaxProtocol,
94
+ conformingTo protocols: [TypeSyntax],
95
in context: some MacroExpansionContext
96
) throws -> [ExtensionDeclSyntax] {
97
+ if protocols.isEmpty {
98
+ return []
99
+ }
100
+
101
let sendableExtension: DeclSyntax =
102
"""
103
extension \(type.trimmed): Sendable {}
0 commit comments