Browse Source

Fix implicit unique_ptr to bool conversion error when compiling with GCC. (#1720)

Tristan Labelle 6 years ago
parent
commit
e9dac9bd79
1 changed files with 1 additions and 1 deletions
  1. 1 1
      include/llvm/IR/ValueMap.h

+ 1 - 1
include/llvm/IR/ValueMap.h

@@ -99,7 +99,7 @@ public:
   explicit ValueMap(const ExtraData &Data, unsigned NumInitBuckets = 64)
       : Map(NumInitBuckets), Data(Data) {}
 
-  bool hasMD() const { return MDMap; }
+  bool hasMD() const { return bool(MDMap); }
   MDMapT &MD() {
     if (!MDMap)
       MDMap.reset(new MDMapT);