[NFC] Fix build failure in ScopDetection
authorChristopher Tetreault <ctetreau@quicinc.com>
Thu, 30 Sep 2021 23:39:48 +0000 (16:39 -0700)
committerChristopher Tetreault <ctetreau@quicinc.com>
Mon, 4 Oct 2021 16:19:27 +0000 (09:19 -0700)
In some build environments, the C++ compiler is unable to infer the
correct type for the DenseMap::insert in isErrorBlock. Typing out
std::make_pair helps.

polly/lib/Analysis/ScopDetection.cpp

index aab8741..4dfcf34 100644 (file)
@@ -1469,7 +1469,7 @@ bool ScopDetection::isErrorBlock(llvm::BasicBlock &BB, const llvm::Region &R) {
   if (!PollyAllowErrorBlocks)
     return false;
 
-  auto It = ErrorBlockCache.insert({{&BB, &R}, false});
+  auto It = ErrorBlockCache.insert({std::make_pair(&BB, &R), false});
   if (!It.second)
     return It.first->getSecond();