|
13 | 13 | // This file provides compatibility aliases to keep dependents of SwiftSyntax building.
|
14 | 14 | // All users of the declarations in this file should transition away from them ASAP.
|
15 | 15 |
|
| 16 | +public extension AccessorEffectSpecifiersSyntax { |
| 17 | + @available(*, deprecated, message: "use throwsClause instead of throwsSpecifier") |
| 18 | + init( |
| 19 | + leadingTrivia: Trivia? = nil, |
| 20 | + asyncSpecifier: TokenSyntax? = nil, |
| 21 | + throwsSpecifier: TokenSyntax? = nil, |
| 22 | + trailingTrivia: Trivia? = nil |
| 23 | + ) { |
| 24 | + self.init( |
| 25 | + leadingTrivia: leadingTrivia, |
| 26 | + asyncSpecifier: asyncSpecifier, |
| 27 | + throwsClause: throwsSpecifier.map { ThrowsClauseSyntax(throwsSpecifier: $0) }, |
| 28 | + trailingTrivia: trailingTrivia |
| 29 | + ) |
| 30 | + } |
| 31 | +} |
| 32 | + |
16 | 33 | extension AttributeSyntax {
|
17 | 34 | @available(*, deprecated, renamed: "Arguments")
|
18 | 35 | public typealias Argument = Arguments
|
@@ -475,6 +492,23 @@ public extension TokenSyntax {
|
475 | 492 | }
|
476 | 493 | }
|
477 | 494 |
|
| 495 | +public extension TypeEffectSpecifiersSyntax { |
| 496 | + @available(*, deprecated, message: "use throwsClause instead of throwsSpecifier") |
| 497 | + init( |
| 498 | + leadingTrivia: Trivia? = nil, |
| 499 | + asyncSpecifier: TokenSyntax? = nil, |
| 500 | + throwsSpecifier: TokenSyntax? = nil, |
| 501 | + trailingTrivia: Trivia? = nil |
| 502 | + ) { |
| 503 | + self.init( |
| 504 | + leadingTrivia: leadingTrivia, |
| 505 | + asyncSpecifier: asyncSpecifier, |
| 506 | + throwsClause: throwsSpecifier.map { ThrowsClauseSyntax(throwsSpecifier: $0) }, |
| 507 | + trailingTrivia: trailingTrivia |
| 508 | + ) |
| 509 | + } |
| 510 | +} |
| 511 | + |
478 | 512 | //==========================================================================//
|
479 | 513 | // IMPORTANT: If you are tempted to add a compatibility layer code here //
|
480 | 514 | // please insert it in alphabetical order above //
|
|
0 commit comments