<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
</head>
<body>
<p>Hi Richard,</p>
<p>I don't really "need" any of these patches. Just that it seems
wrong to me that a program using exprseq::prepend() does not
compile. But maybe that is intended because it is really
inefficient?<br>
</p>
<div class="moz-cite-prefix">Am 05.03.22 um 20:24 schrieb Richard B.
Kreckel:<br>
</div>
<blockquote type="cite"
cite="mid:26bb43c5-75c4-de5e-6baa-d7aa8cd1e66e@in.terlu.de">
<pre class="moz-quote-pre" wrap="">Hi Jan,
On 05.03.22 15:18, Jan Rheinländer wrote:
</pre>
<blockquote type="cite">
<pre class="moz-quote-pre" wrap="">here are two patches: One for push_front() / pop_front(), the other for sort().
</pre>
</blockquote>
<pre class="moz-quote-pre" wrap="">
Are you sure you want to container<std::vector>::prepend()? It's very
slow. For std::list and std::deque, .push_front() and .insert(.begin)
seem to be equally fast. So, your first patch techniqually at least not
a regression.
Your second patch makes container::sort_(std::input_iterator_tag) use
std::sort. That seems wrong to me because std::sort requires a random
access iterator. And std::list iterators are only bidirectional, not
random access. (Note that random_access_iterator_tag is derived from
input_iterator_tag.) Could you explain why you needed this second patch?
-richy.
_______________________________________________
GiNaC-devel mailing list
<a class="moz-txt-link-abbreviated" href="mailto:GiNaC-devel@ginac.de">GiNaC-devel@ginac.de</a>
<a class="moz-txt-link-freetext" href="https://www.ginac.de/mailman/listinfo/ginac-devel">https://www.ginac.de/mailman/listinfo/ginac-devel</a>
</pre>
</blockquote>
</body>
</html>