aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/Basic/VirtualFileSystem.cpp
diff options
context:
space:
mode:
authorRafael Espindola <rafael.espindola@gmail.com>2014-05-31 01:26:30 +0000
committerRafael Espindola <rafael.espindola@gmail.com>2014-05-31 01:26:30 +0000
commitcb82dfb11c95e671dbacd66a066114e7e88678ac (patch)
tree346de5579d44cff0f9af1e58b1d2a642576263ae /clang/lib/Basic/VirtualFileSystem.cpp
parent63ed1a35193abc706bd808931572b98e11502f25 (diff)
downloadllvm-cb82dfb11c95e671dbacd66a066114e7e88678ac.zip
llvm-cb82dfb11c95e671dbacd66a066114e7e88678ac.tar.gz
llvm-cb82dfb11c95e671dbacd66a066114e7e88678ac.tar.bz2
Use error_code() instead of error_code::succes()
There is no std::error_code::success, so this removes much of the noise in transitioning to std::error_code. llvm-svn: 209949
Diffstat (limited to 'clang/lib/Basic/VirtualFileSystem.cpp')
-rw-r--r--clang/lib/Basic/VirtualFileSystem.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/clang/lib/Basic/VirtualFileSystem.cpp b/clang/lib/Basic/VirtualFileSystem.cpp
index a469c9a..1892839 100644
--- a/clang/lib/Basic/VirtualFileSystem.cpp
+++ b/clang/lib/Basic/VirtualFileSystem.cpp
@@ -142,7 +142,7 @@ error_code RealFile::close() {
if (::close(FD))
return error_code(errno, system_category());
FD = -1;
- return error_code::success();
+ return error_code();
}
void RealFile::setName(StringRef Name) {
@@ -175,7 +175,7 @@ error_code RealFileSystem::openFileForRead(const Twine &Name,
return EC;
Result.reset(new RealFile(FD));
Result->setName(Name.str());
- return error_code::success();
+ return error_code();
}
IntrusiveRefCntPtr<FileSystem> vfs::getRealFileSystem() {
@@ -829,7 +829,7 @@ error_code VFSFromYAML::openFileForRead(const Twine &Path,
if (!F->useExternalName(UseExternalNames))
Result->setName(Path.str());
- return error_code::success();
+ return error_code();
}
IntrusiveRefCntPtr<FileSystem>