220 25846 <1f37ba85-fbfe-4a00-97fd-ac9125111bea@isocpp.org> article
Path: news.gmane.org!not-for-mail
From: Nicol Bolas <jmckesson@gmail.com>
Newsgroups: gmane.comp.lang.c++.isocpp.proposals
Subject: Re: Fixed-size views and spans
Date: Sun, 8 May 2016 06:40:38 -0700 (PDT)
Lines: 81
Approved: news@gmane.org
Message-ID: <1f37ba85-fbfe-4a00-97fd-ac9125111bea@isocpp.org>
References: <09bfdbe7-70d9-4d25-9f51-4b79cecfb79f@isocpp.org>
Reply-To: std-proposals@isocpp.org
NNTP-Posting-Host: plane.gmane.org
Mime-Version: 1.0
Content-Type: multipart/mixed; 
	boundary="----=_Part_2199_227591671.1462714838609"
X-Trace: ger.gmane.org 1462714843 22121 80.91.229.3 (8 May 2016 13:40:43 GMT)
X-Complaints-To: usenet@ger.gmane.org
NNTP-Posting-Date: Sun, 8 May 2016 13:40:43 +0000 (UTC)
To: ISO C++ Standard - Future Proposals <std-proposals@isocpp.org>
Original-X-From: std-proposals+bncBCEKFTV6ZUMBBV4DXW4QKGQEAVD47GI@isocpp.org Sun May 08 15:40:43 2016
Return-path: <std-proposals+bncBCEKFTV6ZUMBBV4DXW4QKGQEAVD47GI@isocpp.org>
Envelope-to: gclcip-std-proposals@m.gmane.org
Original-Received: from mail-vk0-f70.google.com ([209.85.213.70])
	by plane.gmane.org with esmtp (Exim 4.69)
	(envelope-from <std-proposals+bncBCEKFTV6ZUMBBV4DXW4QKGQEAVD47GI@isocpp.org>)
	id 1azOwr-0005El-MD
	for gclcip-std-proposals@m.gmane.org; Sun, 08 May 2016 15:40:41 +0200
Original-Received: by mail-vk0-f70.google.com with SMTP id e126sf88215957vkb.2
        for <gclcip-std-proposals@m.gmane.org>; Sun, 08 May 2016 06:40:41 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=isocpp-org.20150623.gappssmtp.com; s=20150623;
        h=date:from:to:message-id:in-reply-to:references:subject:mime-version
         :x-original-sender:reply-to:precedence:mailing-list:list-id
         :x-spam-checked-in-group:list-post:list-help:list-archive
         :list-subscribe:list-unsubscribe;
        bh=xQApLGXR8ZesHfG9pwxeEH4C2ZgMN2c554cQM3R+/iQ=;
        b=whEVFX/Nm7vgIzboAb0crvIDJ6ywC9JWCGSokBFxy6YEXKvfhWhthNyYdDM2vRyMdi
         Dv6kHvDca9q9MVrtpJeVvTypNJLh++wGCD18CNnw1vPGlmyYvK72TRvb9t05h6Dqvbw5
         NmGpPRHGQKGse/5jhGoRN7PCcGZAkETSQaQjql4pDOSB7tc2KooxHuFpe5QfDsFuyxhg
         yQ1wxBcDsmKWCb8PwAsZgrXJ4Af5pXPcZ5ep4SIuEzqrR/VPVH6cUQdGpDA1Z2ebXMzj
         D/OXDorO93Mqv/UgfAu35dm0KYyzfpQwgcXwkYGyTwU2ulCCsdmdpUKzhk5rm+xmEUPG
         EwwQ==
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
         :x-spam-checked-in-group:list-post:list-help:list-archive
         :list-subscribe:list-unsubscribe;
        bh=xQApLGXR8ZesHfG9pwxeEH4C2ZgMN2c554cQM3R+/iQ=;
        b=J0gMulJg3DLq1YHJWdOFTncfgqX07Tfqn9reRoNsATJO7fkRsQ5xK4NUec1eE0lYDo
         s8bcUE8xH//pqKf+AYtNSPlXEgA+9uLHLTxZ7+2bhvxk3YaBfm4fvObTQGQd8/38Bohj
         7wg4SVsvl46JG5B8emaUBrOFo0/G+ttgWs7FYwnpifcwBmlBnnqesfBk3SfxVOABoeSk
         m0A/ZLFrZb1X/kW+ZYSZjFJWsYkE2jCSh1gzsP9o59al2xSTzmucKxoaxQJYuyTDg44x
         gm6Zia+RDvUHeHeE9Q0MpdQRcKD78flWBcna/2UL6snVCePE2JjHhUigjvPsxtf2r/R6
         MzrA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=1e100.net; s=20130820;
        h=x-gm-message-state:date:from:to:message-id:in-reply-to:references
         :subject:mime-version:x-original-sender:reply-to:precedence
         :mailing-list:list-id:x-spam-checked-in-group:list-post:list-help
         :list-archive:list-subscribe:list-unsubscribe;
        bh=xQApLGXR8ZesHfG9pwxeEH4C2ZgMN2c554cQM3R+/iQ=;
        b=Q5/cfKUbIrvJFsY6JuSVQLVvu8eQtDOsVo9MBMrVA4feNdnZhsqutTxTtvEeuAA5tY
         M6t+dttWSn4gGafzp44Yt1p6k6SM45TQRHyyPhnH72thrVyAqH4bBJHGuRTx4xXblmkv
         VjTGHoEAVVijTAghrNTUFPlUvUb3lQIV7QbuRfRSnsU8SeGKHnnoCTNwzpsAzxo4pyib
         pXxZQoYb1Kvdm1xyYGur+bcm80kubG4dP9HWyQ9KA+dAXByrzy6vmaWEHNIc1A9LPteh
         Wdrpv02c/MFyDSr2fuqp9xY8/p66PcKBrI+PDMnWjfG/yICvR9grocIyCdiD35jauMsS
         V/2w==
X-Gm-Message-State: AOPr4FWn7W+BlMnYSInKgyiSrR19pg2ldF6cbIfRTd3XQoZFUWsRujKYS17qw9d4aDHaWw==
X-Received: by 10.140.30.203 with SMTP id d69mr13301270qgd.19.1462714840676;
        Sun, 08 May 2016 06:40:40 -0700 (PDT)
X-BeenThere: std-proposals@isocpp.org
Original-Received: by 10.50.3.66 with SMTP id a2ls966829iga.43.gmail; Sun, 08 May 2016
 06:40:39 -0700 (PDT)
X-Received: by 10.50.182.7 with SMTP id ea7mr71597igc.2.1462714839626;
        Sun, 08 May 2016 06:40:39 -0700 (PDT)
In-Reply-To: <09bfdbe7-70d9-4d25-9f51-4b79cecfb79f@isocpp.org>
X-Original-Sender: jmckesson@gmail.com
Precedence: list
Mailing-list: list std-proposals@isocpp.org; contact std-proposals+owners@isocpp.org
List-ID: <std-proposals.isocpp.org>
X-Spam-Checked-In-Group: std-proposals@isocpp.org
X-Google-Group-Id: 399137483710
List-Post: <https://groups.google.com/a/isocpp.org/group/std-proposals/post>, <mailto:std-proposals@isocpp.org>
List-Help: <https://support.google.com/a/isocpp.org/bin/topic.py?topic=25838>, <mailto:std-proposals+help@isocpp.org>
List-Archive: <https://groups.google.com/a/isocpp.org/group/std-proposals/>
List-Subscribe: <https://groups.google.com/a/isocpp.org/group/std-proposals/subscribe>,
 <mailto:std-proposals+subscribe@isocpp.org>
List-Unsubscribe: <mailto:googlegroups-manage+399137483710+unsubscribe@googlegroups.com>,
 <https://groups.google.com/a/isocpp.org/group/std-proposals/subscribe>
Xref: news.gmane.org gmane.comp.lang.c++.isocpp.proposals:25846
Archived-At: <http://permalink.gmane.org/gmane.comp.lang.c++.isocpp.proposals/25846>

------=_Part_2199_227591671.1462714838609
Content-Type: multipart/alternative; 
	boundary="----=_Part_2200_620974199.1462714838610"

------=_Part_2200_620974199.1462714838610
Content-Type: text/plain; charset=UTF-8

The GSL `span` type already supports being compile-time sized. Being 
dynamically sized is simply a specialization.

As for specializations in standard library algorithms... I don't much care 
for that. Sure, they can be *allowed*, but we shouldn't expect them.

First, WikiSort seems to be able to work based solely on random-access 
iterators. So it's not clear why we would need specializations for that. 
Also WikiSort appears to have an implicit requirement of `value_type` being 
default constructible (for the cache), which is not something that 
`stable_sort` requires. So it could not be a general replacement in the 
library (though this requirement may merely be lazy programming, not a 
requirement of the algorithm).

Second, if I have a need for the properties of WikiSort, it would be silly 
of me to just use `stable_sort` and hope that the implementation provides 
this specializations. Yes, quality-of-implementation matters, but that is 
simply expecting way too much from your implementation. The standard 
library is a general tool for general uses; if you need such specific 
algorithms, then you *need* specific algorithms.

I wouldn't be against having a few of these newer sorting algorithms added 
to the standard library. But they should be new functions which have the 
explicit behavior of their particular algorithms.

-- 
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 email to std-proposals+unsubscribe@isocpp.org.
To post to this group, send email to std-proposals@isocpp.org.
To view this discussion on the web visit https://groups.google.com/a/isocpp.org/d/msgid/std-proposals/1f37ba85-fbfe-4a00-97fd-ac9125111bea%40isocpp.org.

------=_Part_2200_620974199.1462714838610
Content-Type: text/html; charset=UTF-8
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr">The GSL `span` type already supports being compile-time si=
zed. Being dynamically sized is simply a specialization.<br><br>As for spec=
ializations in standard library algorithms... I don&#39;t much care for tha=
t. Sure, they can be <i>allowed</i>, but we shouldn&#39;t expect them.<br><=
br>First, WikiSort seems to be able to work based solely on random-access i=
terators. So it&#39;s not clear why we would need specializations for that.=
 Also WikiSort appears to have an implicit requirement of `value_type` bein=
g default constructible (for the cache), which is not something that `stabl=
e_sort` requires. So it could not be a general replacement in the library (=
though this requirement may merely be lazy programming, not a requirement o=
f the algorithm).<br><br>Second, if I have a need for the properties of Wik=
iSort, it would be silly of me to just use `stable_sort` and hope that the =
implementation provides this specializations. Yes, quality-of-implementatio=
n matters, but that is simply expecting way too much from your implementati=
on. The standard library is a general tool for general uses; if you need su=
ch specific algorithms, then you <i>need</i> specific algorithms.<br><br>I =
wouldn&#39;t be against having a few of these newer sorting algorithms adde=
d to the standard library. But they should be new functions which have the =
explicit behavior of their particular algorithms.<br></div>

<p></p>

-- <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 <a href=3D"mailto:std-proposals+unsubscribe@isocpp.org">std-proposa=
ls+unsubscribe@isocpp.org</a>.<br />
To post to this group, send email to <a href=3D"mailto:std-proposals@isocpp=
..org">std-proposals@isocpp.org</a>.<br />
To view this discussion on the web visit <a href=3D"https://groups.google.c=
om/a/isocpp.org/d/msgid/std-proposals/1f37ba85-fbfe-4a00-97fd-ac9125111bea%=
40isocpp.org?utm_medium=3Demail&utm_source=3Dfooter">https://groups.google.=
com/a/isocpp.org/d/msgid/std-proposals/1f37ba85-fbfe-4a00-97fd-ac9125111bea=
%40isocpp.org</a>.<br />

------=_Part_2200_620974199.1462714838610--
------=_Part_2199_227591671.1462714838609--

.
