Introduce a DirectoryEntryRef that stores both a reference and an
authorAlex Lorenz <arphaman@gmail.com>
Sat, 31 Aug 2019 01:26:04 +0000 (01:26 +0000)
committerAlex Lorenz <arphaman@gmail.com>
Sat, 31 Aug 2019 01:26:04 +0000 (01:26 +0000)
commit0377ca641c9af0262270d091578cab19523b1bc6
tree07dd78901eff6d926370fdd5414576a90fdfd40e
parent09490012afde4ef89165f42d143e18a81e7a1054
Introduce a DirectoryEntryRef that stores both a reference and an
accessed name to the directory entry

This commit introduces a parallel API that returns a DirectoryEntryRef
to the FileManager, similar to the parallel FileEntryRef API. All
uses will have to be update in follow-up patches. The immediate use of the new API in this
patch fixes the issue where a file manager was reused in clang-scan-deps,
but reported an different file path whenever a framework lookup was done through a symlink.

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

llvm-svn: 370562
clang/include/clang/Basic/FileManager.h
clang/include/clang/Lex/DirectoryLookup.h
clang/lib/Basic/FileManager.cpp
clang/lib/Frontend/InitHeaderSearch.cpp
clang/lib/Lex/HeaderSearch.cpp
clang/lib/Lex/PPDirectives.cpp
clang/test/ClangScanDeps/Inputs/subframework_header_dir_symlink_cdb.json
clang/test/ClangScanDeps/subframework_header_dir_symlink.m
clang/unittests/Lex/HeaderSearchTest.cpp
clang/unittests/Lex/PPCallbacksTest.cpp