ClangTool will make FileManager mix up two header files with the same relative path in different absolute paths.
As the cache of previously opened FileEntry in FileManager is indexed by the file name, when relative paths are used as the index, wrong FileEntry may be used for the file with the same relative path. With ClangTool, as the current working directory will change when parsing multiple files, files with the same relative paths but different absolute paths will be mixed up by the FileManager.
Submit on behalf of Hao Zhang <zhanghao19@ios.ac.cn>, I will forward the reviews and his replies.
clang-format: please reformat the code