220 8634 <CAPBZbvxxWut4gwA_wM0hAfnk1qaMKS9k__WYJLS_fEf6cCAdzA@mail.gmail.com> article
Path: news.gmane.org!not-for-mail
From: "Billy O'Neal" <billy.oneal@gmail.com>
Newsgroups: gmane.comp.lang.c++.isocpp.proposals
Subject: Re: string_view::is_null()
Date: Thu, 16 Jan 2014 15:10:12 -0800
Lines: 118
Approved: news@gmane.org
Message-ID: <CAPBZbvxxWut4gwA_wM0hAfnk1qaMKS9k__WYJLS_fEf6cCAdzA@mail.gmail.com>
References: <52d6c23b.6f8a440a.74c7.1675@mx.google.com> <1abccd12-9b4f-49ab-8cfd-bad8878f09af@isocpp.org>
Reply-To: std-proposals@isocpp.org
NNTP-Posting-Host: plane.gmane.org
Mime-Version: 1.0
Content-Type: multipart/alternative; boundary=001a11c204f289c7e704f01e89da
X-Trace: ger.gmane.org 1389913847 32027 80.91.229.3 (16 Jan 2014 23:10:47 GMT)
X-Complaints-To: usenet@ger.gmane.org
NNTP-Posting-Date: Thu, 16 Jan 2014 23:10:47 +0000 (UTC)
To: std-proposals <std-proposals@isocpp.org>
Original-X-From: std-proposals+bncBDKLBLVE6ADBB7WN4GLAKGQEQLM4KZI@isocpp.org Fri Jan 17 00:10:56 2014
Return-path: <std-proposals+bncBDKLBLVE6ADBB7WN4GLAKGQEQLM4KZI@isocpp.org>
Envelope-to: gclcip-std-proposals@m.gmane.org
Original-Received: from mail-qa0-f70.google.com ([209.85.216.70])
	by plane.gmane.org with esmtp (Exim 4.69)
	(envelope-from <std-proposals+bncBDKLBLVE6ADBB7WN4GLAKGQEQLM4KZI@isocpp.org>)
	id 1W3w5P-0004qx-Vi
	for gclcip-std-proposals@m.gmane.org; Fri, 17 Jan 2014 00:10:56 +0100
Original-Received: by mail-qa0-f70.google.com with SMTP id ii20sf4810884qab.9
        for <gclcip-std-proposals@m.gmane.org>; Thu, 16 Jan 2014 15:10:55 -0800 (PST)
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=1e100.net; s=20130820;
        h=x-gm-message-state:mime-version:in-reply-to:references:from:date
         :message-id:subject:to:x-original-sender
         :x-original-authentication-results:reply-to:precedence:mailing-list
         :list-id:list-post:list-help:list-archive:list-subscribe
         :list-unsubscribe:content-type;
        bh=c86IRt9u5ZR/5pVkwrtvDfyfL+gorRX+VNuWMOYNL9g=;
        b=LDP0dTkcBGyJS/bt3HqfT43NpjmhyRIXvU17jqBlI5chDghz4733d5CmAI5IOCoiJU
         pEMyFhrHnFitvb8saumwfOduoU1cLXijW4zQStZ1pKZIhOSXyYnPf9QY6B64/PhKmozv
         Dktpgx5khkNy47Mf5pV61HmCFtrCtALg1+0+Tr+q7uJ9TZ6HS9J8J6gb+dLFuQ2PjbJN
         gu4M+mo+KS4hU0M2hgFEdJYsnsxl1mtc+MxnwvJ1DWdlVrXG7vxveyPaYe1BnWjKRP+1
         W9tktj/HZS+7Gr6G94UUBtFDc+5rFi/4mOgKNK/JMo49uud4TPNCUjuDYjnFOypfrtL+
         Khyg==
X-Gm-Message-State: ALoCoQm26xZX2NgK9N9yU54ot9TfIcDVQoibJWNlQRMmeKmLdbu/1rgPBaLdaTkaRqf2jQyn+sWX
X-Received: by 10.236.149.198 with SMTP id x46mr4164686yhj.7.1389913855176;
        Thu, 16 Jan 2014 15:10:55 -0800 (PST)
X-BeenThere: std-proposals@isocpp.org
Original-Received: by 10.140.88.227 with SMTP id t90ls363855qgd.52.gmail; Thu, 16 Jan
 2014 15:10:54 -0800 (PST)
X-Received: by 10.236.77.231 with SMTP id d67mr5689459yhe.113.1389913854602;
        Thu, 16 Jan 2014 15:10:54 -0800 (PST)
Original-Received: from mail-ob0-x236.google.com (mail-ob0-x236.google.com [2607:f8b0:4003:c01::236])
        by mx.google.com with ESMTPS id q66si12227215yhm.104.2014.01.16.15.10.54
        for <std-proposals@isocpp.org>
        (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128);
        Thu, 16 Jan 2014 15:10:54 -0800 (PST)
Received-SPF: pass (google.com: domain of billy.oneal@gmail.com designates 2607:f8b0:4003:c01::236 as permitted sender) client-ip=2607:f8b0:4003:c01::236;
Original-Received: by mail-ob0-f182.google.com with SMTP id wn1so3535828obc.41
        for <std-proposals@isocpp.org>; Thu, 16 Jan 2014 15:10:54 -0800 (PST)
X-Received: by 10.182.243.161 with SMTP id wz1mr9472034obc.10.1389913854034;
 Thu, 16 Jan 2014 15:10:54 -0800 (PST)
Original-Received: by 10.182.87.37 with HTTP; Thu, 16 Jan 2014 15:10:12 -0800 (PST)
In-Reply-To: <1abccd12-9b4f-49ab-8cfd-bad8878f09af@isocpp.org>
X-Original-Sender: billy.oneal@gmail.com
X-Original-Authentication-Results: mx.google.com;       spf=pass (google.com:
 domain of billy.oneal@gmail.com designates 2607:f8b0:4003:c01::236 as
 permitted sender) smtp.mail=billy.oneal@gmail.com;       dkim=pass
 header.i=@gmail.com;       dmarc=pass (p=NONE dis=NONE) header.from=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:8634
Archived-At: <http://permalink.gmane.org/gmane.comp.lang.c++.isocpp.proposals/8634>

--001a11c204f289c7e704f01e89da
Content-Type: text/plain; charset=UTF-8

What do you expect

to_string(foo);

to return if foo is a null string_view?

Billy O'Neal
https://github.com/BillyONeal/ <https://bitbucket.org/BillyONeal/>
http://stackoverflow.com/users/82320/billy-oneal


On Thu, Jan 16, 2014 at 2:46 PM, Casey Carter <cartec69@gmail.com> wrote:

> On Wednesday, January 15, 2014 11:15:36 AM UTC-6, Billy O'Neal wrote:
>>
>> It should be discouraged because we don't want to have to write null
>> checks in every function under the sun; it is about preventing callers from
>> supplying unexpected results.
>>
>
> "Every function under the sun" must already be able to deal with an empty
> string_view, given that a null string_view must also necessarily be empty,
> there's no need to check for null as a special case.
>
> --
>
> ---
> 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.
> Visit this group at
> http://groups.google.com/a/isocpp.org/group/std-proposals/.
>

-- 

--- 
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.
Visit this group at http://groups.google.com/a/isocpp.org/group/std-proposals/.

--001a11c204f289c7e704f01e89da
Content-Type: text/html; charset=UTF-8
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr"><div>What do you expect</div><div><br></div><div>to_string=
(foo);</div><div><br></div><div>to return if foo is a null string_view?</di=
v></div><div class=3D"gmail_extra"><br clear=3D"all"><div><div dir=3D"ltr">=
<div>

Billy O&#39;Neal</div><div><a href=3D"https://bitbucket.org/BillyONeal/" ta=
rget=3D"_blank">https://github.com/BillyONeal/</a></div><div><a href=3D"htt=
p://stackoverflow.com/users/82320/billy-oneal" target=3D"_blank">http://sta=
ckoverflow.com/users/82320/billy-oneal</a></div>

</div></div>
<br><br><div class=3D"gmail_quote">On Thu, Jan 16, 2014 at 2:46 PM, Casey C=
arter <span dir=3D"ltr">&lt;<a href=3D"mailto:cartec69@gmail.com" target=3D=
"_blank">cartec69@gmail.com</a>&gt;</span> wrote:<br><blockquote class=3D"g=
mail_quote" style=3D"margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-l=
eft:1ex">

<div dir=3D"ltr">On Wednesday, January 15, 2014 11:15:36 AM UTC-6, Billy O&=
#39;Neal wrote:<blockquote class=3D"gmail_quote" style=3D"margin:0px 0px 0p=
x 0.8ex;padding-left:1ex;border-left-color:rgb(204,204,204);border-left-wid=
th:1px;border-left-style:solid">

<div style=3D"font-family:Calibri,sans-serif;font-size:12pt"><div>It should=
 be discouraged because we don&#39;t want to have to write null checks in e=
very function under the sun; it is about preventing callers from supplying =
unexpected results.</div>

</div></blockquote><div><br></div><div>&quot;Every function under the sun&q=
uot; must already be able to deal with an empty string_view, given that a n=
ull string_view must also necessarily be empty, there&#39;s no need to chec=
k for null as a special case.</div>

</div><span class=3D"HOEnZb"><font color=3D"#888888">

<p></p>

-- <br>
=C2=A0<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 <a href=3D"mailto:std-proposals%2Bunsubscribe@isocpp.org" target=3D=
"_blank">std-proposals+unsubscribe@isocpp.org</a>.<br>
To post to this group, send email to <a href=3D"mailto:std-proposals@isocpp=
..org" target=3D"_blank">std-proposals@isocpp.org</a>.<br>
Visit this group at <a href=3D"http://groups.google.com/a/isocpp.org/group/=
std-proposals/" target=3D"_blank">http://groups.google.com/a/isocpp.org/gro=
up/std-proposals/</a>.<br>
</font></span></blockquote></div><br></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 />

--001a11c204f289c7e704f01e89da--

.
