You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Sep 27, 2023. It is now read-only.
In my case, the file contains an include to another file in the same folder.
However, due to -working-directory=/home/user, clang is unable to locate this file.
The text was updated successfully, but these errors were encountered:
I'd really like to use this plugin, but this error persists.
I tried to craft a patch fixing this bug, which turned out to basically remove the try block in buildClangArgs.
However, I hit another problem then: When completing in a header file, clang complains about having #pragma once in the main file and refuses to give any completions.
This can be fixed by using echo "#include \"filename.h\"" | clang++ instead of cat filename.h | clang++, i.e. simply changing the input option in codeCompletionAt().
This however requires that the file is actually saved before performing autocompletion...
I've just looked into this, as I'm affected this bug as well. The issue lies in the "clang-flags" package, which always adds a -working-directory=#{searchDir} parameter to the clang call, where searchDir is the directory of the .clang_complete file. I think this should be fixed in clang-flags, but workarounding it in autocomplete-clang would also be easy.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
When I try to autocomplete in a file (say /home/user/project/test.h), the clang commandline looks like this:
In my case, the file contains an include to another file in the same folder.
However, due to -working-directory=/home/user, clang is unable to locate this file.
The text was updated successfully, but these errors were encountered: