Improves Clang's virtual file handling.
authorZhanyong Wan <wan@google.com>
Fri, 11 Feb 2011 18:44:49 +0000 (18:44 +0000)
committerZhanyong Wan <wan@google.com>
Fri, 11 Feb 2011 18:44:49 +0000 (18:44 +0000)
commit9b555ea217565ac0f8bf7255b29496916cb03476
treed69320c0be0391236ed81495c3f468ea91e5acdf
parentb7a1841244418b658bcf64573ff0c00867fb9c5d
Improves Clang's virtual file handling.

This patch contains:

- making some of the existing comments more accurate in the presence
of virtual files/directories.

- renaming some private data members of FileManager to match their roles better.

- creating 'DirectorEntry's for the parent directories of virtual
files, such that we can tell whether two virtual files are from the
same directory.  This is useful for injecting virtual files whose
directories don't exist in the real file system.

- minor clean-ups and adding comments for class
FileManager::UniqueDirContainer and FileManager::UniqueFileContainer.

- adding statistics on virtual files to FileManager::PrintStats().

- adding unit tests to verify the existing and new behavior of FileManager.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@125384 91177308-0d34-0410-b5e6-96231b3b80d8
include/clang/Basic/FileManager.h
lib/Basic/FileManager.cpp
unittests/FileManager/FileManagerTest.cpp [new file with mode: 0644]
unittests/FileManager/Makefile [new file with mode: 0644]
unittests/Makefile