Fix breakage from r211244 by using LLVM_EXPLICIT to avoid using explicit operators under MSVC where they're not supported.

llvm-svn: 211246
This commit is contained in:
David Blaikie 2014-06-19 01:09:49 +00:00
parent 92fc741998
commit d3d6de2703

View File

@ -29,6 +29,7 @@
#ifndef LLVM_SUPPORT_STRINGPOOL_H #ifndef LLVM_SUPPORT_STRINGPOOL_H
#define LLVM_SUPPORT_STRINGPOOL_H #define LLVM_SUPPORT_STRINGPOOL_H
#include "llvm/Support/Compiler.h"
#include "llvm/ADT/StringMap.h" #include "llvm/ADT/StringMap.h"
#include <cassert> #include <cassert>
#include <new> #include <new>
@ -128,7 +129,7 @@ namespace llvm {
} }
inline const char *operator*() const { return begin(); } inline const char *operator*() const { return begin(); }
inline explicit operator bool() const { return S != nullptr; } inline LLVM_EXPLICIT operator bool() const { return S != nullptr; }
inline bool operator==(const PooledStringPtr &That) const { return S == That.S; } inline bool operator==(const PooledStringPtr &That) const { return S == That.S; }
inline bool operator!=(const PooledStringPtr &That) const { return S != That.S; } inline bool operator!=(const PooledStringPtr &That) const { return S != That.S; }