220 8103 <6bc64055-23b0-464f-b617-ef30d0f756b4@isocpp.org> article
Path: news.gmane.org!not-for-mail
From: mitchnull@gmail.com
Newsgroups: gmane.comp.lang.c++.isocpp.proposals
Subject: Re: Re: Proposal: Private extension methods
Date: Wed, 11 Dec 2013 01:23:00 -0800 (PST)
Lines: 80
Approved: news@gmane.org
Message-ID: <6bc64055-23b0-464f-b617-ef30d0f756b4@isocpp.org>
References: <05028bfb-6f6f-4ee8-9a6e-7e6eaa3a877a@isocpp.org>	<64d699c7-62e0-48ce-9c58-c9b7a6038832@isocpp.org>	<CAOU91ONGstr-ieMJnQ0VB3aDqf2FJmRZef3U_xQYPaR=BsDXug@mail.gmail.com>	<1902602.AxIk4I1HBX@tjmaciei-mobl2>	<52A79CD3.50802@wanadoo.fr> <CAFk2RUacEe5dsjONcEiBa9MSxmKh9TCpA5A8-sNAA2xc=v-VCQ@mail.gmail.com>
 <52A7B319.1090308@gmail.com>
 <566b4320-4f64-4d14-ac61-6eb94c536967@isocpp.org>
Reply-To: std-proposals@isocpp.org
NNTP-Posting-Host: plane.gmane.org
Mime-Version: 1.0
Content-Type: multipart/alternative; 
	boundary="----=_Part_1160_22385915.1386753780961"
X-Trace: ger.gmane.org 1386753781 7558 80.91.229.3 (11 Dec 2013 09:23:01 GMT)
X-Complaints-To: usenet@ger.gmane.org
NNTP-Posting-Date: Wed, 11 Dec 2013 09:23:01 +0000 (UTC)
Cc: fmatthew5876@gmail.com
To: std-proposals@isocpp.org
Original-X-From: std-proposals+bncBC36XNFZ4YKBB5W5UCKQKGQE2MEE5RA@isocpp.org Wed Dec 11 10:23:03 2013
Return-path: <std-proposals+bncBC36XNFZ4YKBB5W5UCKQKGQE2MEE5RA@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+bncBC36XNFZ4YKBB5W5UCKQKGQE2MEE5RA@isocpp.org>)
	id 1Vqg0V-000463-Fv
	for gclcip-std-proposals@m.gmane.org; Wed, 11 Dec 2013 10:23:03 +0100
Original-Received: by mail-qa0-f70.google.com with SMTP id j5sf885448qaq.5
        for <gclcip-std-proposals@m.gmane.org>; Wed, 11 Dec 2013 01:23:02 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=gmail.com; s=20120113;
        h=date:from:to:cc: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=2KJyVry8qKrziM/jbRHiH1P5vFsOaeLnVIOlQ+f0EWA=;
        b=Udh5RSqho32eoUsEEMmVkoX4pWptqVKDZCIdArc4/xkgwskiDrNSpAFWErjD5QJv3z
         5FrVRKU3Kh/k2syJxUNqct1o9DwLbODdShN5kCy51wOSDhfBZSx85jaCBpj7MQE5urEC
         he9yyr5lZyd64gIfc2qLUY/q9RnjvNIi21Pbps6pf5wWp3riRjoDb8w0OaGlbM26USaf
         2xQ0126lb0YR2gcLW3Gy2X7xlzj1hKAKIiA3L9+M14tBlt0C3dHfOLj3KW3lkBDE3vXM
         3BASzcRxOmpP6qhcDjXZSceyW4josVhcAGCBHMuOuNKMhsszHSya2Me0Cns1fWvl6R/Z
         J9xA==
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:cc: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=2KJyVry8qKrziM/jbRHiH1P5vFsOaeLnVIOlQ+f0EWA=;
        b=KgGRsEnYaSpKeIlbm6Va0Na9OYBAKJIVLdNkxhviBBtbNP+g6IERUNNCipzSxhf5Sl
         BN8haL9Z38b2diLF90iqduCgHpKpt7o7VzjVfsKzZJWrkn7LJ3LkzAqYizMKHH80meg3
         O+PxqP7QPBlu3dUBVouSC2qlE6G7y3xko+z7sQH79UnJJvNqMuYx8GjxnkQ1fSrdvNef
         7GPGYdiWaZUuWkqvoi0yAf9FNYE2qJJ2lCpBhHV4C072u5Xau5eeTfL8a7dZbgfJzyGB
         6QHGU+S8JQcuWEMGyLWTfq4a2mm22dOdlA1lre9t3TOiQ0CdAX6kVk/KTgTDL+XpsOfQ
         zjTA==
X-Gm-Message-State: ALoCoQlQfcGPCWcpfzWEYsB4+/olhWZmjEcHiPy2waRonD/MblTpaC8t0ybfHHXcy0UW0hYrUp2V
X-Received: by 10.236.220.39 with SMTP id n37mr108410yhp.15.1386753782670;
        Wed, 11 Dec 2013 01:23:02 -0800 (PST)
X-BeenThere: std-proposals@isocpp.org
Original-Received: by 10.182.138.9 with SMTP id qm9ls14986obb.14.gmail; Wed, 11 Dec
 2013 01:23:01 -0800 (PST)
X-Received: by 10.182.138.66 with SMTP id qo2mr5165obb.8.1386753781893;
        Wed, 11 Dec 2013 01:23:01 -0800 (PST)
In-Reply-To: <566b4320-4f64-4d14-ac61-6eb94c536967@isocpp.org>
X-Original-Sender: mitchnull@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:8103
Archived-At: <http://permalink.gmane.org/gmane.comp.lang.c++.isocpp.proposals/8103>

------=_Part_1160_22385915.1386753780961
Content-Type: text/plain; charset=ISO-8859-1



On Wednesday, December 11, 2013 3:55:11 AM UTC+1, fmatth...@gmail.com wrote:

[SNIP]
 

> Actually using a keyword nicely solves the static dilemna:
>
> private Foo::f1() //private extension method
> private static Foo::f2() //static private method
> static private Foo::f3() //private extension method with internal linkage
> static private static Foo::f4() //static private extension method with 
> internal linkage
>
> Going to think about it more, maybe using the private keyword makes sense.
>

I think using the private keyword like this is good, but I would prefer to 
make all PEMs internal linkage by default and use extern or some other 
keyword in the few cases where you want them to be reachable from other TUs 
and still not declare them in the class.
Also, making  "private static" and "static private" different things is 
just too confusing / ugly in my opinion (but that's minor compared to my 
strong preference towards making PEMs internal linkage by default, thus 
avoiding this use of the static keyword here).


-- 

--- 
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/.

------=_Part_1160_22385915.1386753780961
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr"><br><br>On Wednesday, December 11, 2013 3:55:11 AM UTC+1, =
fmatth...@gmail.com wrote:<div><br></div><div><div><span style=3D"font-size=
: 13px;">[SNIP]</span></div><div>&nbsp;</div><blockquote class=3D"gmail_quo=
te" style=3D"margin: 0;margin-left: 0.8ex;border-left: 1px #ccc solid;paddi=
ng-left: 1ex;"><div dir=3D"ltr"><div><span style=3D"font-size: 13px;">Actua=
lly using a keyword nicely solves the static dilemna:</span><br></div><div>=
<div><br></div><div>private Foo::f1() //private extension method</div><div>=
private static Foo::f2() //static private method</div><div>static private F=
oo::f3() //private extension method with internal linkage</div><div>static =
private static Foo::f4() //static private extension method with internal li=
nkage</div><div><br></div><div>Going to think about it more, maybe using th=
e private keyword makes sense.</div></div></div></blockquote><div><br></div=
><div>I think using the private keyword like this is good, but I would pref=
er to make all PEMs internal linkage by default and use extern or some othe=
r keyword in the few cases where you want them to be reachable from other T=
Us and still not declare them in the class.</div><div>Also, making &nbsp;"p=
rivate static" and "static private" different things is just too confusing =
/ ugly in my opinion (but that's minor compared to my strong preference tow=
ards making PEMs internal linkage by default, thus avoiding this use of the=
 static keyword here).</div></div><div><br></div><div><br></div></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_1160_22385915.1386753780961--

.
