Skip to content

Commit

Permalink
Update swift-indexstore, closes #659, #673
Browse files Browse the repository at this point in the history
  • Loading branch information
ileitch committed Dec 18, 2023
1 parent 8732653 commit cee94df
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 3 deletions.
4 changes: 2 additions & 2 deletions Package.resolved
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,8 @@
"kind" : "remoteSourceControl",
"location" : "https://github.com/ileitch/swift-indexstore",
"state" : {
"revision" : "246d455063ddc8faf3ad791c4488e1f60c59aabd",
"version" : "9.0.3"
"revision" : "e0046a1704e2e7af88355883247ee1f9d47ed9ee",
"version" : "9.0.4"
}
},
{
Expand Down
2 changes: 1 addition & 1 deletion Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ var dependencies: [Package.Dependency] = [
.package(url: "https://github.com/jpsim/Yams", from: "5.0.0"),
.package(url: "https://github.com/tadija/AEXML", from: "4.0.0"),
.package(url: "https://github.com/apple/swift-argument-parser", from: "1.0.0"),
.package(url: "https://github.com/ileitch/swift-indexstore", from: "9.0.3"),
.package(url: "https://github.com/ileitch/swift-indexstore", from: "9.0.4"),
.package(url: "https://github.com/apple/swift-syntax", from: "509.0.2"),
.package(url: "https://github.com/ileitch/swift-filename-matcher", from: "0.0.0"),
]
Expand Down
4 changes: 4 additions & 0 deletions Sources/PeripheryKit/Indexer/Declaration.swift
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@ final class Declaration {
case functionAccessorMutableaddress = "function.accessor.mutableaddress"
case functionAccessorSetter = "function.accessor.setter"
case functionAccessorWillset = "function.accessor.willset"
case functionAccessorRead = "function.accessor.read"
case functionAccessorModify = "function.accessor.modify"
case functionAccessorInit = "function.accessor.init"
case functionConstructor = "function.constructor"
case functionDestructor = "function.destructor"
case functionFree = "function.free"
Expand All @@ -40,6 +43,7 @@ final class Declaration {
case varLocal = "var.local"
case varParameter = "var.parameter"
case varStatic = "var.static"
case macro = "macro"

static var functionKinds: Set<Kind> {
Set(Kind.allCases.filter { $0.isFunctionKind })
Expand Down
4 changes: 4 additions & 0 deletions Sources/PeripheryKit/Indexer/SwiftIndexer.swift
Original file line number Diff line number Diff line change
Expand Up @@ -673,6 +673,9 @@ public final class SwiftIndexer: Indexer {
case .swiftAccessorWillSet: return .functionAccessorWillset
case .swiftAccessorMutableAddressor: return .functionAccessorMutableaddress
case .swiftAccessorAddressor: return .functionAccessorAddress
case .swiftAccessorRead: return .functionAccessorRead
case .swiftAccessorModify: return .functionAccessorModify
case .swiftAccessorInit: return .functionAccessorInit
case .swiftSubscript: return .functionSubscript
case .swiftInfixOperator: return .functionOperatorInfix
case .swiftPrefixOperator: return .functionOperatorPrefix
Expand Down Expand Up @@ -706,6 +709,7 @@ public final class SwiftIndexer: Indexer {
case .constructor: return .functionConstructor
case .destructor: return .functionDestructor
case .parameter: return .varParameter
case .macro: return .macro
default: return nil
}
}
Expand Down

0 comments on commit cee94df

Please sign in to comment.