summaryrefslogtreecommitdiff
path: root/unittests/Tooling/RefactoringTest.cpp
diff options
context:
space:
mode:
authorBenjamin Kramer <benny.kra@googlemail.com>2014-10-26 22:44:13 +0000
committerBenjamin Kramer <benny.kra@googlemail.com>2014-10-26 22:44:13 +0000
commit0273eb0d7a5e729f299341d608b41a4a896735af (patch)
treea51c83113a4d2b3e46b6be2342d64b5c286fd8fd /unittests/Tooling/RefactoringTest.cpp
parenta877a4c5d70706adf2ab0e3402fb875019553c75 (diff)
downloadclang-0273eb0d7a5e729f299341d608b41a4a896735af.tar.gz
Make VFS and FileManager match the current MemoryBuffer API.
This eliminates converting back and forth between the 3 formats and gives us a more homogeneous interface. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@220657 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'unittests/Tooling/RefactoringTest.cpp')
-rw-r--r--unittests/Tooling/RefactoringTest.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/unittests/Tooling/RefactoringTest.cpp b/unittests/Tooling/RefactoringTest.cpp
index 73c53aa842..4935bdd806 100644
--- a/unittests/Tooling/RefactoringTest.cpp
+++ b/unittests/Tooling/RefactoringTest.cpp
@@ -251,9 +251,8 @@ public:
// descriptor, which might not see the changes made.
// FIXME: Figure out whether there is a way to get the SourceManger to
// reopen the file.
- std::unique_ptr<const llvm::MemoryBuffer> FileBuffer(
- Context.Files.getBufferForFile(Path, nullptr));
- return FileBuffer->getBuffer();
+ auto FileBuffer = Context.Files.getBufferForFile(Path);
+ return (*FileBuffer)->getBuffer();
}
llvm::StringMap<std::string> TemporaryFiles;