Files
swift-mirror/tools/SourceKit/lib/SwiftLang/CMakeLists.txt
Nathan Hawes 388052b6ab [SymbolGraph][CursorInfo] Add option to SourceKit's CursorInfo request to include the SymbolGraph JSON
Adds a new 'key.retrieve_symbol_graph' option to the request. When set to 1 it
includes the JSON for a SymbolGraph containing a single node for the symbol at
the requested position.

This also extends the SymbolGraph library with a new entry point to get a graph
for a single symbol, and to additionally support type substitution to match the
existing CursorInfo behavior (e.g. so that when invoked on `first` in
`Array<Int>().first`, the type is given as `Int?` rather than `Element?`).

Resolves rdar://problem/70551509
2020-12-12 14:38:41 +10:00

67 lines
1.2 KiB
CMake

add_sourcekit_library(SourceKitSwiftLang
CodeCompletionOrganizer.cpp
SwiftASTManager.cpp
SwiftCompletion.cpp
SwiftConformingMethodList.cpp
SwiftDocSupport.cpp
SwiftEditor.cpp
SwiftEditorInterfaceGen.cpp
SwiftIndexing.cpp
SwiftLangSupport.cpp
SwiftSourceDocInfo.cpp
SwiftTypeContextInfo.cpp
LLVM_LINK_COMPONENTS ${LLVM_TARGETS_TO_BUILD}
bitreader
bitwriter
coverage
debuginfodwarf
instrumentation
ipo
lto
mc
mcparser
option
objcarcopts
profiledata
)
target_link_libraries(SourceKitSwiftLang PRIVATE
SourceKitCore
swiftDriver
swiftFrontend
swiftClangImporter
swiftIDE
swiftAST
swiftMarkup
swiftParse
swiftSIL
swiftSILGen
swiftSILOptimizer
swiftIRGen
swiftSema
swiftBasic
swiftSerialization
swiftSyntax
swiftOption
swiftSymbolGraphGen
libcmark_static
# Clang dependencies.
clangIndex
clangFormat
clangToolingCore
clangFrontendTool
clangFrontend
clangDriver
clangCodeGen
clangSerialization
clangParse
clangSema
clangAnalysis
clangEdit
clangRewriteFrontend
clangRewrite
clangLex
clangAST
clangAPINotes
clangBasic)
add_dependencies(SourceKitSwiftLang clang-tablegen-targets)