PPC: Add some missing V_SET0 patterns
[oota-llvm.git] / lib / Support / Windows / Windows.h
index 275407503559ef57b0b22c507acab3ba30410cca..4cdac788a0ed4ff872b7145a503a1582ad203ee3 100644 (file)
@@ -25,6 +25,7 @@
 #define WIN32_LEAN_AND_MEAN
 
 #include "llvm/Config/config.h" // Get build system configuration settings
+#include "llvm/Support/Compiler.h"
 #include <windows.h>
 #include <wincrypt.h>
 #include <shlobj.h>
@@ -75,7 +76,7 @@ public:
   }
 
   // True if Handle is valid.
-  operator bool() const {
+  LLVM_EXPLICIT operator bool() const {
     return HandleTraits::IsValid(Handle) ? true : false;
   }
 
@@ -128,24 +129,6 @@ struct FindHandleTraits : CommonHandleTraits {
   }
 };
 
-struct FileMappingHandleTraits : CommonHandleTraits {
-  static handle_type GetInvalid() {
-    return 0;
-  }
-};
-
-struct MappedViewOfFileHandleTraits : CommonHandleTraits {
-  typedef LPVOID handle_type;
-
-  static handle_type GetInvalid() {
-    return 0;
-  }
-
-  static void Close(handle_type h) {
-    ::UnmapViewOfFile(h);
-  }
-};
-
 struct FileHandleTraits : CommonHandleTraits {};
 
 typedef ScopedHandle<CommonHandleTraits> ScopedCommonHandle;
@@ -153,8 +136,6 @@ typedef ScopedHandle<FileHandleTraits>   ScopedFileHandle;
 typedef ScopedHandle<CryptContextTraits> ScopedCryptContext;
 typedef ScopedHandle<FindHandleTraits>   ScopedFindHandle;
 typedef ScopedHandle<JobHandleTraits>    ScopedJobHandle;
-typedef ScopedHandle<FileMappingHandleTraits> ScopedFileMappingHandle;
-typedef ScopedHandle<MappedViewOfFileHandleTraits> ScopedMappedViewOfFileHandle;
 
 namespace llvm {
 template <class T>