DirectoryWatcher-windows.cpp 1.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. //===- DirectoryWatcher-windows.cpp - Windows-platform directory watching -===//
  2. //
  3. // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
  4. // See https://llvm.org/LICENSE.txt for license information.
  5. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
  6. //
  7. //===----------------------------------------------------------------------===//
  8. // TODO: This is not yet an implementation, but it will make it so Windows
  9. // builds don't fail.
  10. #include "DirectoryScanner.h"
  11. #include "clang/DirectoryWatcher/DirectoryWatcher.h"
  12. #include "llvm/ADT/STLExtras.h"
  13. #include "llvm/ADT/ScopeExit.h"
  14. #include "llvm/Support/AlignOf.h"
  15. #include "llvm/Support/Errno.h"
  16. #include "llvm/Support/Mutex.h"
  17. #include "llvm/Support/Path.h"
  18. #include <atomic>
  19. #include <condition_variable>
  20. #include <mutex>
  21. #include <queue>
  22. #include <string>
  23. #include <thread>
  24. #include <vector>
  25. namespace {
  26. using namespace llvm;
  27. using namespace clang;
  28. class DirectoryWatcherWindows : public clang::DirectoryWatcher {
  29. public:
  30. ~DirectoryWatcherWindows() override { }
  31. void InitialScan() { }
  32. void EventReceivingLoop() { }
  33. void StopWork() { }
  34. };
  35. } // namespace
  36. llvm::Expected<std::unique_ptr<DirectoryWatcher>>
  37. clang::DirectoryWatcher::create(
  38. StringRef Path,
  39. std::function<void(llvm::ArrayRef<DirectoryWatcher::Event>, bool)> Receiver,
  40. bool WaitForInitialSync) {
  41. return llvm::Expected<std::unique_ptr<DirectoryWatcher>>(
  42. llvm::errorCodeToError(std::make_error_code(std::errc::not_supported)));
  43. }