<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 - std::sort_heap use (possible deleted) operator,"
href="https://bugs.llvm.org/show_bug.cgi?id=43063">43063</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>std::sort_heap use (possible deleted) operator,
</td>
</tr>
<tr>
<th>Product</th>
<td>libc++
</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>normal
</td>
</tr>
<tr>
<th>Priority</th>
<td>P
</td>
</tr>
<tr>
<th>Component</th>
<td>All Bugs
</td>
</tr>
<tr>
<th>Assignee</th>
<td>unassignedclangbugs@nondot.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>yichen.yan@inf.ethz.ch
</td>
</tr>
<tr>
<th>CC</th>
<td>llvm-bugs@lists.llvm.org, mclow.lists@gmail.com
</td>
</tr></table>
<p>
<div>
<pre>Created <span class=""><a href="attachment.cgi?id=22402" name="attach_22402" title="test.cc">attachment 22402</a> <a href="attachment.cgi?id=22402&action=edit" title="test.cc">[details]</a></span>
test.cc
Summary: std::sort_heap use (possible deleted) operator, and failed to compile
if it's deleted.
Steps to Reproduce: clang++ -o /dev/null -std=c++11 --compile test.cc
(test.cc attched)
Actual Results:
In file included from test.cc:1:
/home/yiyan/.local/bin/../include/c++/v1/algorithm:4998:67: error: overload
resolution selected deleted operator ','
for (difference_type __n = __last - __first; __n > 1; --__last, --__n)
~~~~~~~~^ ~~~~~
/home/yiyan/.local/bin/../include/c++/v1/algorithm:5008:5: note: in
instantiation of function template specialization
'std::__1::__sort_heap<std::__1::__less<int, int> &,
random_access_iterator_wrapper<int> >' requested here
__sort_heap<_Comp_ref>(__first, __last, __comp);
^
/home/yiyan/.local/bin/../include/c++/v1/algorithm:5016:12: note: in
instantiation of function template specialization
'std::__1::sort_heap<random_access_iterator_wrapper<int>, std::__1::__less<int,
int> >' requested here
_VSTD::sort_heap(__first, __last, __less<typename
iterator_traits<_RandomAccessIterator>::value_type>());
^
test.cc:33:10: note: in instantiation of function template specialization
'std::__1::sort_heap<random_access_iterator_wrapper<int> >' requested here
std::sort_heap(sortcon.begin(), sortcon.end());
^
test.cc:23:10: note: candidate function [with U = long] has been explicitly
deleted
void operator,(U) = delete;
^
1 error generated.
Expected Results: No error
Build Date & Hardware: Build 2019-08-20 on Linux x86_64</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>