Remove dead code (#5004)

Identified with the upcoming improved dead code detection.
This commit is contained in:
JP Simard 2023-05-12 14:20:31 -04:00 committed by GitHub
parent 866001db2f
commit 1e73835e83
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 0 additions and 15 deletions

View File

@ -147,10 +147,6 @@ public extension ModifierListSyntax? {
}
}
var isFinal: Bool {
contains(tokenKind: .keyword(.final))
}
private func contains(tokenKind: TokenKind) -> Bool {
guard let modifiers = self else {
return false
@ -347,12 +343,6 @@ public extension IdentifierExprSyntax {
}
}
public extension MemberAccessExprSyntax {
var isSelfAccess: Bool {
base?.as(IdentifierExprSyntax.self)?.isSelf == true
}
}
public extension ClosureCaptureItemSyntax {
var capturesSelf: Bool {
expression.as(IdentifierExprSyntax.self)?.isSelf == true

View File

@ -5,11 +5,6 @@ public struct Stack<Element> {
/// Creates an empty `Stack`.
public init() {}
/// True if the stack has no elements. False otherwise.
public var isEmpty: Bool {
elements.isEmpty
}
/// The number of elements in this stack.
public var count: Int {
elements.count