Skip to content

CompilationDatabaseBuildSystem should account for working directory #1856

Closed
@bkolb

Description

@bkolb

Swift version

swiftlang-6.1.0.101.24 clang-1700.0.4.22

Platform

macOS

Editor

VSCode

Description

I have configured sourcekit-lsp in VSCode to use compile-commands extracted from bazel.
Trying to resolve reverse references fails. The reason is that my path pointing to the global index is relative to the working directory. Once converted to an absolute path, it works.
The candidate could be here: https://github.com/swiftlang/sourcekit-lsp/blob/main/Sources/BuildSystemIntegration/CompilationDatabaseBuildSystem.swift#L91-L109

Steps to Reproduce

No response

Logging

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions