<html>
<head>
<base href="https://bugs.llvm.org/">
</head>
<body><table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Bug ID</th>
<td><a class="bz_bug_link
bz_status_NEW "
title="NEW - Clang could diagnose failure to construct a pair w/ braced init sequence better"
href="https://bugs.llvm.org/show_bug.cgi?id=37645">37645</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>Clang could diagnose failure to construct a pair w/ braced init sequence better
</td>
</tr>
<tr>
<th>Product</th>
<td>new-bugs
</td>
</tr>
<tr>
<th>Version</th>
<td>unspecified
</td>
</tr>
<tr>
<th>Hardware</th>
<td>PC
</td>
</tr>
<tr>
<th>OS</th>
<td>Linux
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>enhancement
</td>
</tr>
<tr>
<th>Priority</th>
<td>P
</td>
</tr>
<tr>
<th>Component</th>
<td>new bugs
</td>
</tr>
<tr>
<th>Assignee</th>
<td>unassignedbugs@nondot.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>chandlerc@gmail.com
</td>
</tr>
<tr>
<th>CC</th>
<td>llvm-bugs@lists.llvm.org
</td>
</tr></table>
<p>
<div>
<pre>Hacking on LLVM I got the following diagnostic:
/home/chandlerc/src/llvm/project/llvm/lib/Transforms/Scalar/SimpleLoopUnswitch.cpp:1932:26:
error: no matching member function for call to 'push_back'
UnswitchCandidates.push_back({BI, {BI->getCondition()}});
~~~~~~~~~~~~~~~~~~~^~~~~~~~~
/home/chandlerc/src/llvm/project/llvm/include/llvm/ADT/SmallVector.h:212:8:
note: candidate function not viable: cannot convert initializer list argument
to 'const std::__1::pair<llvm::TerminatorInst *,
llvm::TinyPtrVector<llvm::Value *> >'
void push_back(const T &Elt) {
^
/home/chandlerc/src/llvm/project/llvm/include/llvm/ADT/SmallVector.h:219:8:
note: candidate function not viable: cannot convert initializer list argument
to 'std::__1::pair<llvm::TerminatorInst *, llvm::TinyPtrVector<llvm::Value *>
<span class="quote">>'</span >
void push_back(T &&Elt) {
^
The problem is that TinyPtrVector<T> doesn't have an initializer list
constructor.</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are on the CC list for the bug.</li>
</ul>
</body>
</html>