Skip to content

Commit 3b7f138

Browse files
committed
Add namespace case for NavigatorIndex.PageType.
1 parent 86ea063 commit 3b7f138

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

Sources/SwiftDocC/Indexing/Navigator/NavigatorIndex.swift

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -309,6 +309,9 @@ public class NavigatorIndex {
309309
case languageGroup = 127
310310
case container = 254
311311
case groupMarker = 255 // UInt8.max
312+
313+
// C++ symbols
314+
case namespace = 48
312315

313316
/// Initialize a page type from a `role` and a `symbolKind` returning the Symbol type.
314317
init(symbolKind: String) {
@@ -336,6 +339,7 @@ public class NavigatorIndex {
336339
case "enumcm", "structcm", "clm", "intfcm", "type.method": self = .typeMethod
337340
case "httpget", "httpput", "httppost", "httppatch", "httpdelete": self = .httpRequest
338341
case "dict": self = .dictionarySymbol
342+
case "namespace": self = .namespace
339343
default: self = .symbol
340344
}
341345
}

Sources/SwiftDocC/Indexing/RenderIndexJSON/RenderIndex.swift

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -364,6 +364,8 @@ extension NavigatorIndex.PageType {
364364
return "httpRequest"
365365
case .dictionarySymbol:
366366
return "dictionarySymbol"
367+
case .namespace:
368+
return SymbolGraph.Symbol.KindIdentifier.namespace.renderingIdentifier
367369
case .propertyListKeyReference:
368370
return "propertyListKeyReference"
369371
case .languageGroup:

0 commit comments

Comments
 (0)