diff options
author | Chris Lattner <sabre@nondot.org> | 2010-11-23 09:19:42 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2010-11-23 09:19:42 +0000 |
commit | 75dfb65c38d51772df9a00ce2d2feeefd55667ad (patch) | |
tree | e7cbb532a7424c29765febd45a7f941f38d6a248 /include/clang/Basic/FileManager.h | |
parent | 681c74afe6a81161aa13291c6c114e5240b23865 (diff) |
tidy up. Split FileManager::getBufferForFile into
two copies, since they are fundamentally different
operations and the StringRef one should go away
(it shouldn't be part of FileManager at least).
Remove some dead arguments.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@120013 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/clang/Basic/FileManager.h')
-rw-r--r-- | include/clang/Basic/FileManager.h | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/include/clang/Basic/FileManager.h b/include/clang/Basic/FileManager.h index 5a143e9441..12e9e3f227 100644 --- a/include/clang/Basic/FileManager.h +++ b/include/clang/Basic/FileManager.h @@ -171,7 +171,7 @@ class FileManager { // Caching. llvm::OwningPtr<StatSysCallCache> StatCache; - int stat_cached(const char* path, struct stat* buf); + int stat_cached(const char *path, struct stat *buf); public: FileManager(const FileSystemOptions &FileSystemOpts); @@ -212,12 +212,9 @@ public: /// \brief Open the specified file as a MemoryBuffer, returning a new /// MemoryBuffer if successful, otherwise returning null. llvm::MemoryBuffer *getBufferForFile(const FileEntry *Entry, - std::string *ErrorStr = 0) { - return getBufferForFile(Entry->getName(), ErrorStr, Entry->getSize()); - } + std::string *ErrorStr = 0); llvm::MemoryBuffer *getBufferForFile(llvm::StringRef Filename, - std::string *ErrorStr = 0, - int64_t FileSize = -1); + std::string *ErrorStr = 0); /// \brief If path is not absolute and FileSystemOptions set the working /// directory, the path is modified to be relative to the given |