Skip to content

Commit 7ed3ed8

Browse files
committed
[Docs] Document the @_spiOnly attribute
1 parent b680084 commit 7ed3ed8

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

docs/ReferenceGuides/UnderscoredAttributes.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -451,6 +451,13 @@ This prevents types from that module being exposed in API
451451
(types of public functions, constraints in public extension etc.)
452452
and ABI (usage in `@inlinable` code).
453453

454+
## `@_spiOnly`
455+
456+
Marks an import to be used in SPI and implementation details only.
457+
The import statement will be printed in the private swiftinterface only and
458+
skipped in the public swiftinterface. Any use of imported types and decls in API
459+
will be diagnosed.
460+
454461
## `@_implements(ProtocolName, Requirement)`
455462

456463
An attribute that indicates that a function with one name satisfies

0 commit comments

Comments
 (0)