-
Notifications
You must be signed in to change notification settings - Fork 12.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Incorrect non-portable path warning. #130
Comments
I did a bit more digging. The issue only occurs when running on an NTFS partition mounted in case-insensitive mode (the default). However, the drive's case sensitivity shouldn't matter here: the two "common" directories are in different locations and Thread.hpp only exists in one of them. Here's the output when the command is run with the
You can see that it's trying to import "Thread.hpp" twice, but using different paths. |
Interesting! The mistaken warning doesn't occur on linux using a case-insensitive vfat filesystem. However, the incorrect capitalization of "./common/Thread.hpp" does also occur in that situation. On both OSes, LLVM has decided to process On linux, even after opening "common/Thread.hpp" (with the wrong case), it determines the full path with correct case (/<...wherever...>/Common/Thread.hpp) of the opened file descriptor, via the readlink call in "openFileForRead" in llvm/lib/Support/Unix/Path.inc. I wonder if that's not happening on windows. |
Hi, I'm experiencing this issue with clangd on Windows. I get the following warning:
But my file is in delayGraph/delayGraph (notice capital G) This is the screenshot of the warning in VS Code: |
@llvm/issue-subscribers-clang-frontend Author: Marcus T (llamasoft)
I ran into this issue while attempting to build Chromium from source. I can confirm that this issue occurs on at least clang versions 7.0.1-8 (installed via apt) and 10.0.0 (from the Chromium build chain). It should be noted that I was doing this build under the Windows Subsystem for Linux running Ubuntu.
Here are some shell commands to create the file and directory structure needed to reproduce the issue:
The result will be:
This is absolutely incorrect. The file It should be noted that the issue seems to have some rather specific criteria for being triggered. For example, the file being built must be at a different folder depth than the other files. Furthermore, the order of the This seems possibly related to bug 32436, but that one appears to involve symlinks whereas this one only involves actual files. |
I ran into this issue while attempting to build Chromium from source. I can confirm that this issue occurs on at least clang versions 7.0.1-8 (installed via apt) and 10.0.0 (from the Chromium build chain). It should be noted that I was doing this build under the Windows Subsystem for Linux running Ubuntu.
Here are some shell commands to create the file and directory structure needed to reproduce the issue:
The result will be:
This is absolutely incorrect. The file
common/Thread.hpp
doesn't even exist, nor was it ever referenced. It seems to be confusing the directory capitalization of./Package/common
and./Common
It should be noted that the issue seems to have some rather specific criteria for being triggered. For example, the file being built must be at a different folder depth than the other files. Furthermore, the order of the
-I
flags matters. When reversed, the issue does not occur.This seems possibly related to bug 32436, but that one appears to involve symlinks whereas this one only involves actual files.
The text was updated successfully, but these errors were encountered: