Closed phreppo closed 6 years ago
Looking at your output, /home/src/type.c
looks like the correct result of combining /home/phreppo/CGen/build
and ../../../src/type.c
.
It would appear that the fileLocation
for the Scan task should have been /home/phreppo/CGen/build/meson-private/tmpsm350_09
in order to resolve the relative path to /home/phreppo/CGen/src/type.c
. Am I missing something?
Setting the problem matcher for the Scan task as:
"problemMatcher": {
"base":"$gcc",
"fileLocation" : ["relative", "${workspaceRoot}/build/meson-private/tmpsm350_09"]
}
solves the problem, thanks!
I'm using Ninja build system to build a C project. I'm using the extension C/Cpp. When i build the project with the Scan task, the extension shows the warnings in the problems panel, but the paths to the files are wrong: they point to upper directories in the file system tree.
Steps to Reproduce:
meson build
Console output with warnings:
Problems panel(pointing to the wrong directory, because my project is located in
/home/phreppo/CGen
):Dialog window that appears when I click on one warning. In this particular example the file that should be opened is
/home/phreppo/CGen/test/type.c
It's curious, because with the task Build the problems points to the right directory, and they have the same
fileLocation
property. Here's the Build task:Does this issue occur when all other extensions are disabled?: Yes
Reopening in Microsoft/cpp-tools from a similar one, but now Build task is ok: the problem is the Scan task.