llvm-project/clang/test/Frontend/absolute-paths-windows.test
Igor Kudrin 0de4e935bb Do not resolve directory junctions for -fdiagnostics-absolute-paths on Windows.
If the source file path contains directory junctions, and we resolve them when
printing diagnostic messages, these paths look independent for an IDE.
For example, both Visual Studio and Visual Studio Code open separate editors
for such paths, which is not only inconvenient but might even result in losing
changes made in one of them.

Differential Revision: https://reviews.llvm.org/D59415

llvm-svn: 361598
2019-05-24 04:46:22 +00:00

10 lines
343 B
Plaintext

// REQUIRES: system-windows
// RUN: rm -rf %t.dir
// RUN: mkdir -p %t.dir\real
// RUN: cmd /c mklink /j %t.dir\junc %t.dir\real
// RUN: echo "wrong code" > %t.dir\real\foo.cpp
// RUN: not %clang_cc1 -fsyntax-only -fdiagnostics-absolute-paths %t.dir\junc\foo.cpp 2>&1 | FileCheck %s
// CHECK-NOT: .dir\real\foo.cpp
// CHECK: .dir\junc\foo.cpp