summaryrefslogtreecommitdiffstats
path: root/clang/lib/DirectoryWatcher/windows
diff options
context:
space:
mode:
authorJan Korous <jkorous@apple.com>2019-08-13 22:39:50 +0000
committerJan Korous <jkorous@apple.com>2019-08-13 22:39:50 +0000
commit9a13852eaba3d6a011009e762a9554112ab7266a (patch)
tree139ef014108c7fd090601bdb3e3faf80936d4027 /clang/lib/DirectoryWatcher/windows
parentb724f3d4b33c4a5966f5feeeb7b2917e25fc9692 (diff)
downloadbcm5719-llvm-9a13852eaba3d6a011009e762a9554112ab7266a.tar.gz
bcm5719-llvm-9a13852eaba3d6a011009e762a9554112ab7266a.zip
[clang][DirectoryWatcher] Fix Windows stub after LLVM change
r367979 changed DirectoryWatcher::Create to return an llvm::Expected. Adjust the Windows stub accordingly. (upstreamed from github.com/apple/swift-clang) llvm-svn: 368762
Diffstat (limited to 'clang/lib/DirectoryWatcher/windows')
-rw-r--r--clang/lib/DirectoryWatcher/windows/DirectoryWatcher-windows.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/clang/lib/DirectoryWatcher/windows/DirectoryWatcher-windows.cpp b/clang/lib/DirectoryWatcher/windows/DirectoryWatcher-windows.cpp
index 6a12715592b..25cbcf53638 100644
--- a/clang/lib/DirectoryWatcher/windows/DirectoryWatcher-windows.cpp
+++ b/clang/lib/DirectoryWatcher/windows/DirectoryWatcher-windows.cpp
@@ -40,9 +40,11 @@ public:
};
} // namespace
-std::unique_ptr<DirectoryWatcher> clang::DirectoryWatcher::create(
+llvm::Expected<std::unique_ptr<DirectoryWatcher>>
+clang::DirectoryWatcher::create(
StringRef Path,
std::function<void(llvm::ArrayRef<DirectoryWatcher::Event>, bool)> Receiver,
bool WaitForInitialSync) {
- return nullptr;
+ return llvm::Expected<std::unique_ptr<DirectoryWatcher>>(
+ llvm::errorCodeToError(std::make_error_code(std::errc::not_supported)));
}
OpenPOWER on IntegriCloud