summaryrefslogtreecommitdiff
path: root/include/clang/Basic/VirtualFileSystem.h
diff options
context:
space:
mode:
authorRafael Espindola <rafael.espindola@gmail.com>2014-06-12 14:02:15 +0000
committerRafael Espindola <rafael.espindola@gmail.com>2014-06-12 14:02:15 +0000
commit9986295b4f4702e5e02102cb257ae71fceedffec (patch)
treed2c566c85a6ef92e698ec19be71888839dc3645a /include/clang/Basic/VirtualFileSystem.h
parent43a42fb5cd0c1eb7a5f3ac97b9d5e77c10bd8c22 (diff)
downloadclang-9986295b4f4702e5e02102cb257ae71fceedffec.tar.gz
clang-9986295b4f4702e5e02102cb257ae71fceedffec.tar.bz2
clang-9986295b4f4702e5e02102cb257ae71fceedffec.tar.xz
Replace llvm::error_code with std::error_code.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@210780 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/clang/Basic/VirtualFileSystem.h')
-rw-r--r--include/clang/Basic/VirtualFileSystem.h29
1 files changed, 15 insertions, 14 deletions
diff --git a/include/clang/Basic/VirtualFileSystem.h b/include/clang/Basic/VirtualFileSystem.h
index 0a9949612c..83e0fb52e5 100644
--- a/include/clang/Basic/VirtualFileSystem.h
+++ b/include/clang/Basic/VirtualFileSystem.h
@@ -89,12 +89,13 @@ public:
/// \brief Get the status of the file.
virtual llvm::ErrorOr<Status> status() = 0;
/// \brief Get the contents of the file as a \p MemoryBuffer.
- virtual llvm::error_code
- getBuffer(const Twine &Name, std::unique_ptr<llvm::MemoryBuffer> &Result,
- int64_t FileSize = -1, bool RequiresNullTerminator = true,
- bool IsVolatile = false) = 0;
+ virtual std::error_code getBuffer(const Twine &Name,
+ std::unique_ptr<llvm::MemoryBuffer> &Result,
+ int64_t FileSize = -1,
+ bool RequiresNullTerminator = true,
+ bool IsVolatile = false) = 0;
/// \brief Closes the file.
- virtual llvm::error_code close() = 0;
+ virtual std::error_code close() = 0;
/// \brief Sets the name to use for this file.
virtual void setName(StringRef Name) = 0;
};
@@ -107,16 +108,16 @@ public:
/// \brief Get the status of the entry at \p Path, if one exists.
virtual llvm::ErrorOr<Status> status(const Twine &Path) = 0;
/// \brief Get a \p File object for the file at \p Path, if one exists.
- virtual llvm::error_code openFileForRead(const Twine &Path,
- std::unique_ptr<File> &Result) = 0;
+ virtual std::error_code openFileForRead(const Twine &Path,
+ std::unique_ptr<File> &Result) = 0;
/// This is a convenience method that opens a file, gets its content and then
/// closes the file.
- llvm::error_code getBufferForFile(const Twine &Name,
- std::unique_ptr<llvm::MemoryBuffer> &Result,
- int64_t FileSize = -1,
- bool RequiresNullTerminator = true,
- bool IsVolatile = false);
+ std::error_code getBufferForFile(const Twine &Name,
+ std::unique_ptr<llvm::MemoryBuffer> &Result,
+ int64_t FileSize = -1,
+ bool RequiresNullTerminator = true,
+ bool IsVolatile = false);
};
/// \brief Gets an \p vfs::FileSystem for the 'real' file system, as seen by
@@ -154,8 +155,8 @@ public:
void pushOverlay(IntrusiveRefCntPtr<FileSystem> FS);
llvm::ErrorOr<Status> status(const Twine &Path) override;
- llvm::error_code openFileForRead(const Twine &Path,
- std::unique_ptr<File> &Result) override;
+ std::error_code openFileForRead(const Twine &Path,
+ std::unique_ptr<File> &Result) override;
};
/// \brief Get a globally unique ID for a virtual file or directory.