220 7170 <231e6ef1-599d-4877-be6c-55e85e5a4e41@isocpp.org> article
Path: news.gmane.org!not-for-mail
From: Evgeny Panasyuk <evgeny.panasyuk@gmail.com>
Newsgroups: gmane.comp.lang.c++.isocpp.proposals
Subject: Re: "count_while" and "count_until" algorithms
Date: Tue, 8 Oct 2013 13:36:57 -0700 (PDT)
Lines: 73
Approved: news@gmane.org
Message-ID: <231e6ef1-599d-4877-be6c-55e85e5a4e41@isocpp.org>
References: <CAOpASk64dV+3ZUW+Z8wcEqug_oSaztvJp1zsDB_QdAxi+fwcsA@mail.gmail.com>
 <fe7981d7-4eaf-4132-9150-4ec7d3ff7ac4@isocpp.org>
 <2602b3fd-fccd-459b-be1a-93a12005dc5c@isocpp.org>
Reply-To: std-proposals@isocpp.org
NNTP-Posting-Host: plane.gmane.org
Mime-Version: 1.0
Content-Type: multipart/alternative; 
	boundary="----=_Part_885_7414682.1381264617980"
X-Trace: ger.gmane.org 1381264617 1094 80.91.229.3 (8 Oct 2013 20:36:57 GMT)
X-Complaints-To: usenet@ger.gmane.org
NNTP-Posting-Date: Tue, 8 Oct 2013 20:36:57 +0000 (UTC)
To: std-proposals@isocpp.org
Original-X-From: std-proposals+bncBC54TLGKR4LBB26Z2GJAKGQEFMHA7UY@isocpp.org Tue Oct 08 22:37:01 2013
Return-path: <std-proposals+bncBC54TLGKR4LBB26Z2GJAKGQEFMHA7UY@isocpp.org>
Envelope-to: gclcip-std-proposals@m.gmane.org
Original-Received: from mail-ob0-f197.google.com ([209.85.214.197])
	by plane.gmane.org with esmtp (Exim 4.69)
	(envelope-from <std-proposals+bncBC54TLGKR4LBB26Z2GJAKGQEFMHA7UY@isocpp.org>)
	id 1VTe1c-0005QW-Vg
	for gclcip-std-proposals@m.gmane.org; Tue, 08 Oct 2013 22:37:01 +0200
Original-Received: by mail-ob0-f197.google.com with SMTP id uy5sf4485443obc.4
        for <gclcip-std-proposals@m.gmane.org>; Tue, 08 Oct 2013 13:37:00 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=gmail.com; s=20120113;
        h=date:from:to:message-id:in-reply-to:references:subject:mime-version
         :x-original-sender:reply-to:precedence:mailing-list:list-id
         :list-post:list-help:list-archive:list-subscribe:list-unsubscribe
         :content-type;
        bh=LdM2noOyADlsIoVLYVghKPK33CmucVWSHI4EuVugpgg=;
        b=DwHyF1FGrl2nya40dVkNTe4ifDDRB+bh7Z5KAD2o83AmnYMPxN0o0zhW3xaBV05J70
         n9+YOljV7+IItehy8vcfEBvmUX6cY40NoA8OMgkgLwIZtQVJ9vlBJRWcF/8EcD5fgjlQ
         JMCEDn+zyuSSEVa7VS+FKFA8Gge/7NOm64vz8qvzcC3SB/wLn8+lif8Lv0tKUBpQITeI
         N855ALBOGU8HEKUg8/VTsb+MhdkGhebQAumN3eoignLmB8tq7G+p/w5FA94WLjVUxoWI
         Ia7YbZKTXVy7HJp3ppx6X6GfumRU0N8BjE2DnOOl/whjP8G0vtMTKpebseAD4YHzTYqW
         y4AA==
X-Received: by 10.42.207.206 with SMTP id fz14mr1970110icb.2.1381264619964;
        Tue, 08 Oct 2013 13:36:59 -0700 (PDT)
X-BeenThere: std-proposals@isocpp.org
Original-Received: by 10.50.12.67 with SMTP id w3ls3828092igb.25.canary; Tue, 08 Oct
 2013 13:36:59 -0700 (PDT)
X-Received: by 10.50.171.169 with SMTP id av9mr201779igc.11.1381264619342;
        Tue, 08 Oct 2013 13:36:59 -0700 (PDT)
In-Reply-To: <2602b3fd-fccd-459b-be1a-93a12005dc5c@isocpp.org>
X-Original-Sender: evgeny.panasyuk@gmail.com
Precedence: list
Mailing-list: list std-proposals@isocpp.org; contact std-proposals+owners@isocpp.org
List-ID: <std-proposals.isocpp.org>
X-Google-Group-Id: 399137483710
List-Post: <http://groups.google.com/a/isocpp.org/group/std-proposals/post>, <mailto:std-proposals@isocpp.org>
List-Help: <http://support.google.com/a/isocpp.org/bin/topic.py?topic=25838>, <mailto:std-proposals+help@isocpp.org>
List-Archive: <http://groups.google.com/a/isocpp.org/group/std-proposals/>
List-Subscribe: <http://groups.google.com/a/isocpp.org/group/std-proposals/subscribe>,
 <mailto:std-proposals+subscribe@isocpp.org>
List-Unsubscribe: <http://groups.google.com/a/isocpp.org/group/std-proposals/subscribe>,
 <mailto:googlegroups-manage+399137483710+unsubscribe@googlegroups.com>
Xref: news.gmane.org gmane.comp.lang.c++.isocpp.proposals:7170
Archived-At: <http://permalink.gmane.org/gmane.comp.lang.c++.isocpp.proposals/7170>

------=_Part_885_7414682.1381264617980
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable

9 oct 2013 =D0=B3., 0:33:18 UTC+4 lefev...@gmail.com :
>
> Yes, the behavior is like find_if + distance, but the performance is=20
> better (except maybe for random access iterator). I propose a template=20
> specialization for random access iterator in order to be at least as fast=
=20
> as find_if + distance.
>
> Le mardi 8 octobre 2013 22:27:10 UTC+2, Evgeny Panasyuk a =C3=A9crit :
>>
>> I think to make it useful - both count and iterator should be returned.=
=20
>> Just think what happens when input range is single pass.
>> Plus, maybe special versions for RandomAccessIterator via compile time=
=20
>> dispatch (with better performance) .
>>
>
Just to clarify: do you see that both count and iterator should be returned=
?

--=20

---=20
You received this message because you are subscribed to the Google Groups "=
ISO C++ Standard - Future Proposals" group.
To unsubscribe from this group and stop receiving emails from it, send an e=
mail to std-proposals+unsubscribe@isocpp.org.
To post to this group, send email to std-proposals@isocpp.org.
Visit this group at http://groups.google.com/a/isocpp.org/group/std-proposa=
ls/.

------=_Part_885_7414682.1381264617980
Content-Type: text/html; charset=UTF-8
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr">9 oct 2013&nbsp;=D0=B3., 0:33:18 UTC+4 lefev...@gmail.com =
:<blockquote class=3D"gmail_quote" style=3D"margin: 0;margin-left: 0.8ex;bo=
rder-left: 1px #ccc solid;padding-left: 1ex;"><div dir=3D"ltr">Yes, the beh=
avior is like find_if + distance, but the performance is better (except may=
be for random access iterator). I propose a template specialization for ran=
dom access iterator in order to be at least as fast as find_if + distance.<=
br><br>Le mardi 8 octobre 2013 22:27:10 UTC+2, Evgeny Panasyuk a =C3=A9crit=
&nbsp;:<blockquote class=3D"gmail_quote" style=3D"margin:0;margin-left:0.8e=
x;border-left:1px #ccc solid;padding-left:1ex"><div dir=3D"ltr">I think to =
make it useful - both count and iterator should be returned. Just think wha=
t happens when input range is single pass.<br>Plus, maybe special versions =
for RandomAccessIterator via compile time dispatch (with better performance=
) .<br></div></blockquote></div></blockquote><div><br><span id=3D"result_bo=
x" class=3D"short_text" lang=3D"en"><span class=3D"hps">Just to clarify</sp=
an></span>: do you see that  both count and iterator should be returned?</d=
iv></div>

<p></p>

-- <br />
&nbsp;<br />
--- <br />
You received this message because you are subscribed to the Google Groups &=
quot;ISO C++ Standard - Future Proposals&quot; group.<br />
To unsubscribe from this group and stop receiving emails from it, send an e=
mail to std-proposals+unsubscribe@isocpp.org.<br />
To post to this group, send email to std-proposals@isocpp.org.<br />
Visit this group at <a href=3D"http://groups.google.com/a/isocpp.org/group/=
std-proposals/">http://groups.google.com/a/isocpp.org/group/std-proposals/<=
/a>.<br />

------=_Part_885_7414682.1381264617980--

.
