220 29106 <1314a997-2f74-4b52-9755-bc9d1deb6982@isocpp.org> article
Path: news.gmane.org!.POSTED!not-for-mail
From: "T. C." <rs2740@gmail.com>
Newsgroups: gmane.comp.lang.c++.isocpp.proposals
Subject: Re: Re: Removing trivial undefined behaviour
Date: Wed, 26 Oct 2016 08:34:06 -0700 (PDT)
Lines: 120
Approved: news@gmane.org
Message-ID: <1314a997-2f74-4b52-9755-bc9d1deb6982@isocpp.org>
References: <35daf87a-bf1d-46de-b16c-c2965fbadc8f@isocpp.org>
 <9e242562-aba1-4f8d-8e0a-b2de34f6a10b@isocpp.org> <d24d9d41-d5ba-47ed-8e98-915f84063a92@isocpp.org>
 <c976d139-ae31-4756-96a6-30a69d81f14d@isocpp.org>
 <CAOHCbiu0Hd7LsMkKGcvxvo7h3TJzjZAuXPWxNT0WuESUfrFCaw@mail.gmail.com>
Reply-To: std-proposals@isocpp.org
NNTP-Posting-Host: blaine.gmane.org
Mime-Version: 1.0
Content-Type: multipart/mixed; 
	boundary="----=_Part_1058_1732431302.1477496046887"
X-Trace: blaine.gmane.org 1477496076 550 195.159.176.226 (26 Oct 2016 15:34:36 GMT)
X-Complaints-To: usenet@blaine.gmane.org
NNTP-Posting-Date: Wed, 26 Oct 2016 15:34:36 +0000 (UTC)
To: ISO C++ Standard - Future Proposals <std-proposals@isocpp.org>
Original-X-From: std-proposals+bncBCQ43G7NQIIRB4EZYPAAKGQEXLB4ZHY@isocpp.org Wed Oct 26 17:34:31 2016
Return-path: <std-proposals+bncBCQ43G7NQIIRB4EZYPAAKGQEXLB4ZHY@isocpp.org>
Envelope-to: gclcip-std-proposals@m.gmane.org
Original-Received: from mail-yw0-f198.google.com ([209.85.161.198])
	by blaine.gmane.org with esmtp (Exim 4.84_2)
	(envelope-from <std-proposals+bncBCQ43G7NQIIRB4EZYPAAKGQEXLB4ZHY@isocpp.org>)
	id 1bzQDQ-0005oz-1R
	for gclcip-std-proposals@m.gmane.org; Wed, 26 Oct 2016 17:34:08 +0200
Original-Received: by mail-yw0-f198.google.com with SMTP id o2sf12385145ywo.0
        for <gclcip-std-proposals@m.gmane.org>; Wed, 26 Oct 2016 08:34:10 -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=qBWMyj0CQ0Q9jIC6xRDDP1wh+hKlDXR71jTsIYF0g1U=;
        b=NT4HDGhoFz0++2Xv74afDyP6oigYyagUgWvyEOb+HdbDZwq5DbGsiRbwnTIgBWut9P
         SLKBMbEbhdOSpvAD1oKwApjrYCNKk350ydet0h8PxgenSzpDRiXN12W3hu0mwBx4stuC
         ktTArihulIPjkLVF7PVbj6u3y8TJs+yFIGfhnxK6OoRHTmCUO+AC8wzmjuublO4UcK5Z
         e37mpmvphawExNcu4nqr+hPgwVmN8vf0PDRJ3AW5ZHXZQRH6OeuyK8MMhDlGOy0xakrF
         hIjeLznMfM7+wBx7oevkY1jpzLUTszuVGXjBAsoCP7UeBVOhWH9WhFJz0soeb0jdqWz/
         tWPw==
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=qBWMyj0CQ0Q9jIC6xRDDP1wh+hKlDXR71jTsIYF0g1U=;
        b=VXZF+uXfXRIgvFRQLlrxLY/9XpDnwpsHoRdXT7GmJAJg4vsSn3E1XqesWMVhX1TBPp
         BlK9hmK3Pz1qx6+DfB+56qROpHrxIs5J2c9oitU0HmBv90u3nRej3QLy3rGsXJvynqWb
         dRA1+3+e82/8YvUc9hZxbFdNhD4CZsjDF7TEvOJnp1OAKg1diSollqKYzJfw737rtW6m
         gUF+Hma6sSgrJQnlCamxJe7jFTpeB/FU5hCzidOXwj4vePkx5mljDJ/6IMd+nbCJ1ELT
         UYAGO5ULhRZnGjJKzYNAYkxGNrb5/Wf17YKLSQbvQ8vLE6fwKlN7h5fp//2WgKSW6Ih1
         OPxw==
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=qBWMyj0CQ0Q9jIC6xRDDP1wh+hKlDXR71jTsIYF0g1U=;
        b=W/+tXUn+4XakLmWciWtg4wFmgAqciguIahe72I5SrXe7/jn7PAnfbFGIQgxHlgCa2t
         GRpJAPDXCru7yss/mitSGH+1SMUVFz+kPfyOQSp8skJT8uRxR4RwBiNYXfkorIb2qAWZ
         fmgL7frU41aC8VJfcgh5XS2gtypt7Omz/KcmzOZ+DuJyXNb6XkWXvMGmau4H3YLD850l
         1QYpksTgHElfSrVzTLUITJ4O9gUxRSlf2NfzOzEfdz15rS2uv9UBV4yscoT0Fi+GMRVy
         UWWILlqAxuKeEYz0Gz0On0iEbbthoMNVKNB7aQbE25FE7vE4BjuJKvCUm0+3GpXFuYFK
         oe9g==
X-Gm-Message-State: ABUngvcTP8OU9L/JXk8Ntm+Zu93UWs5bRRAego5JnHZkZDtD9qKCot9trwVXFJE4ttI23w==
X-Received: by 10.129.81.144 with SMTP id f138mr930894ywb.131.1477496050451;
        Wed, 26 Oct 2016 08:34:10 -0700 (PDT)
X-BeenThere: std-proposals@isocpp.org
Original-Received: by 10.36.17.85 with SMTP id 82ls602166itf.2.gmail; Wed, 26 Oct 2016
 08:34:08 -0700 (PDT)
X-Received: by 10.36.116.130 with SMTP id o124mr600092itc.10.1477496048395;
        Wed, 26 Oct 2016 08:34:08 -0700 (PDT)
In-Reply-To: <CAOHCbiu0Hd7LsMkKGcvxvo7h3TJzjZAuXPWxNT0WuESUfrFCaw@mail.gmail.com>
X-Original-Sender: rs2740@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: <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:29106
Archived-At: <http://permalink.gmane.org/gmane.comp.lang.c++.isocpp.proposals/29106>

------=_Part_1058_1732431302.1477496046887
Content-Type: multipart/alternative; 
	boundary="----=_Part_1059_2124183137.1477496046887"

------=_Part_1059_2124183137.1477496046887
Content-Type: text/plain; charset=UTF-8



On Wednesday, October 26, 2016 at 9:19:15 AM UTC-4, Tony V E wrote:
>
>
>
> On Wed, Oct 26, 2016 at 4:28 AM, T. C. <rs2...@gmail.com <javascript:>> 
> wrote:
>
>>
>>
>> On Wednesday, October 26, 2016 at 3:20:55 AM UTC-4, Hans Guijt wrote:
>>>
>>>
>>> On Wednesday, October 26, 2016 at 9:11:26 AM UTC+2, T. C. wrote:
>>>>
>>>>
>>>> Because they are meant to be used as isdigit((unsigned char) c).
>>>>
>>>  
>>> Great, in that case I'm sure there is no opposition to changing the 
>>> signature to reflect this requirement? It's a much cleaner solution than 
>>> requiring a cast in every invocation, after all.
>>>
>>>
>>>
>> The reason they take int is because they also accept EOF. That's C's 
>> style, for better or worse.
>>
>> In any event, there's no way in hell C++ is going to change this. It's a 
>> massive C compatibility break.
>>
>
> We could maybe overload the function:
>
> int isdigit(int c);
> bool isdigit(char c);
>
> No idea if that is a good idea.
>
>>
>> -- 
> Be seeing you,
> Tony
>

That breaks anything that expects ::isdigit to be unambiguous (e.g., pass 
it to an algorithm). 

-- 
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/1314a997-2f74-4b52-9755-bc9d1deb6982%40isocpp.org.

------=_Part_1059_2124183137.1477496046887
Content-Type: text/html; charset=UTF-8
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr"><br><br>On Wednesday, October 26, 2016 at 9:19:15 AM UTC-4=
, Tony V E wrote:<blockquote class=3D"gmail_quote" style=3D"margin: 0;margi=
n-left: 0.8ex;border-left: 1px #ccc solid;padding-left: 1ex;"><div dir=3D"l=
tr"><br><div><br><div class=3D"gmail_quote">On Wed, Oct 26, 2016 at 4:28 AM=
, T. C. <span dir=3D"ltr">&lt;<a href=3D"javascript:" target=3D"_blank" gdf=
-obfuscated-mailto=3D"AXnNJDx0AQAJ" rel=3D"nofollow" onmousedown=3D"this.hr=
ef=3D&#39;javascript:&#39;;return true;" onclick=3D"this.href=3D&#39;javasc=
ript:&#39;;return true;">rs2...@gmail.com</a>&gt;</span> wrote:<br><blockqu=
ote class=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;border-left:1px #ccc s=
olid;padding-left:1ex"><div dir=3D"ltr"><span><br><br>On Wednesday, October=
 26, 2016 at 3:20:55 AM UTC-4, Hans Guijt wrote:<blockquote class=3D"gmail_=
quote" style=3D"margin:0;margin-left:0.8ex;border-left:1px #ccc solid;paddi=
ng-left:1ex"><div dir=3D"ltr"><br>On Wednesday, October 26, 2016 at 9:11:26=
 AM UTC+2, T. C. wrote:<blockquote class=3D"gmail_quote" style=3D"margin:0;=
margin-left:0.8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir=3D"=
ltr"><div><br></div><div>Because they are meant to be used as isdigit((unsi=
gned char) c).</div></div></blockquote><div>=C2=A0</div><div>Great, in that=
 case I&#39;m sure there is no opposition to changing the signature to refl=
ect this requirement? It&#39;s a much cleaner solution than requiring a cas=
t in every invocation, after all.<br><br><br></div></div></blockquote><div>=
<br></div></span><div>The reason they take int is because they also accept =
EOF. That&#39;s C&#39;s style, for better or worse.</div><div><br></div><di=
v>In any event, there&#39;s no way in hell C++ is going to change this. It&=
#39;s a massive C compatibility break.</div></div></blockquote><div><br></d=
iv><div>We could maybe overload the function:<br><br></div><div>int isdigit=
(int c);<br></div><div>bool isdigit(char c);<br><br></div><div>No idea if t=
hat is a good idea.<br></div><blockquote class=3D"gmail_quote" style=3D"mar=
gin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span>

<p></p></span><br></blockquote></div>-- <br><div><div dir=3D"ltr"><div>Be s=
eeing you,<br></div>Tony<br></div></div></div></div></blockquote><div><br><=
/div><div>That breaks anything that expects ::isdigit=C2=A0to be unambiguou=
s (e.g., pass it to an algorithm).=C2=A0</div></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/1314a997-2f74-4b52-9755-bc9d1deb6982%=
40isocpp.org?utm_medium=3Demail&utm_source=3Dfooter">https://groups.google.=
com/a/isocpp.org/d/msgid/std-proposals/1314a997-2f74-4b52-9755-bc9d1deb6982=
%40isocpp.org</a>.<br />

------=_Part_1059_2124183137.1477496046887--

------=_Part_1058_1732431302.1477496046887--

.
