Files
clang-p2996/clang/test/ClangScanDeps/symlink.cpp
Jan Svoboda b00de4dd41 [clang][deps] Abolish FileManager sharing
This patch removes the ability of a dependency scanning worker to share a `FileManager` instance between individual scans. It's not sound and doesn't provide performance benefits (due to the underlying caching VFS).

Reviewed By: benlangmuir

Differential Revision: https://reviews.llvm.org/D134976
2022-10-04 12:47:22 -07:00

23 lines
705 B
C++

// REQUIRES: shell
// RUN: rm -rf %t.dir
// RUN: rm -rf %t.cdb
// RUN: mkdir -p %t.dir
// RUN: cp %s %t.dir/symlink_input.cpp
// RUN: cp %s %t.dir/symlink_input2.cpp
// RUN: mkdir %t.dir/Inputs
// RUN: cp %S/Inputs/header.h %t.dir/Inputs/header.h
// RUN: ln -s %t.dir/Inputs/header.h %t.dir/Inputs/symlink.h
// RUN: sed -e "s|DIR|%/t.dir|g" %S/Inputs/symlink_cdb.json > %t.cdb
// RUN: clang-scan-deps -compilation-database %t.cdb -j 1 | FileCheck %s
#include "symlink.h"
#include "header.h"
// CHECK: symlink_input.cpp
// CHECK-NEXT: Inputs{{/|\\}}symlink.h
// CHECK-NEXT: Inputs{{/|\\}}header.h
// CHECK: symlink_input2.cpp
// CHECK-NEXT: Inputs{{/|\\}}symlink.h
// CHECK-NEXT: Inputs{{/|\\}}header.h