220 8480 <52CE0F54.5020800@gmail.com> article
Path: news.gmane.org!not-for-mail
From: David Krauss <potswa@gmail.com>
Newsgroups: gmane.comp.lang.c++.isocpp.proposals
Subject: Re: A new keyword for either a type or a variable
 (typical use case for variadic template template)?
Date: Thu, 09 Jan 2014 10:54:12 +0800
Lines: 44
Approved: news@gmane.org
Message-ID: <52CE0F54.5020800@gmail.com>
References: <f4ec2cca-5951-447f-a938-0b2e5e3e233f@isocpp.org> <-5123564187529511709@gmail297201516> <52CB7506.1000906@gmail.com> <CAOfiQqk4rRTRFX3dbcq33z2C190ZHUGRVUhM0WRJehPZEwFJ8g@mail.gmail.com> <62bda680-3dd7-4be8-8ac5-0d2e08bf6d99@isocpp.org> <CAOfiQq=fvi-mzf6mP4B2XBgCeHfimX857Jff+Nz=iUeHW5W1nw@mail.gmail.com> <52CDFB2D.4050703@gmail.com> <-9126987679220332623@gmail297201516>
Reply-To: std-proposals@isocpp.org
NNTP-Posting-Host: plane.gmane.org
Mime-Version: 1.0
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: quoted-printable
X-Trace: ger.gmane.org 1389236054 5642 80.91.229.3 (9 Jan 2014 02:54:14 GMT)
X-Complaints-To: usenet@ger.gmane.org
NNTP-Posting-Date: Thu, 9 Jan 2014 02:54:14 +0000 (UTC)
To: std-proposals@isocpp.org
Original-X-From: std-proposals+bncBCW25A7E3QCRBWU6XCLAKGQENF3XIHI@isocpp.org Thu Jan 09 03:54:20 2014
Return-path: <std-proposals+bncBCW25A7E3QCRBWU6XCLAKGQENF3XIHI@isocpp.org>
Envelope-to: gclcip-std-proposals@m.gmane.org
Original-Received: from mail-pd0-f198.google.com ([209.85.192.198])
	by plane.gmane.org with esmtp (Exim 4.69)
	(envelope-from <std-proposals+bncBCW25A7E3QCRBWU6XCLAKGQENF3XIHI@isocpp.org>)
	id 1W15lE-0001ii-4g
	for gclcip-std-proposals@m.gmane.org; Thu, 09 Jan 2014 03:54:20 +0100
Original-Received: by mail-pd0-f198.google.com with SMTP id g10sf6049829pdj.5
        for <gclcip-std-proposals@m.gmane.org>; Wed, 08 Jan 2014 18:54:19 -0800 (PST)
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=1e100.net; s=20130820;
        h=x-gm-message-state:message-id:date:from:user-agent:mime-version:to
         :subject:references:in-reply-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:content-transfer-encoding;
        bh=v1XZa6dEL8ahFb5QZwNDOdiUpAsVFqDdKj9WWDn5KmI=;
        b=aO5tHiQ4FsCzeer7r0H0LPn+csuZQYGbKMLy/E5ZSeI/gZh64Ax5yX7a7aySeq3Jk/
         lbjKAQlPi9487blTb3En8uUSwgyxyds2aAtGkjiHBku0SdINoMSviWUKEsStEwS8cCgv
         HzVeOTS5oJCNRgT0esFeiigplAQk7Pfj8m88NzWRj31INm77V1yw4hRq/Zdt2AYODU6/
         +y86+TXf4qWjB84YbYUklcZDIL+B4wUXBuIug2RQjnlpYighzvambsNUfSYa+EitBqbX
         WTeKOCyddobongF4t+n5VdTjsteYmUudEOKDQtKh63iz1R69aa0APf9Es3s7Bdts54+L
         qQ7 
X-Gm-Message-State: ALoCoQnpYxL669CkrXaLdBV0+z8Qws3KLr6ySj/DCkGD78Zo0TTprR3gTVZeNAf9H09Bo9JOnBea
X-Received: by 10.66.66.35 with SMTP id c3mr283354pat.12.1389236058979;
        Wed, 08 Jan 2014 18:54:18 -0800 (PST)
X-BeenThere: std-proposals@isocpp.org
Original-Received: by 10.49.95.229 with SMTP id dn5ls832359qeb.48.gmail; Wed, 08 Jan
 2014 18:54:18 -0800 (PST)
X-Received: by 10.236.62.194 with SMTP id y42mr889014yhc.54.1389236058122;
        Wed, 08 Jan 2014 18:54:18 -0800 (PST)
Original-Received: from mail-oa0-x231.google.com (mail-oa0-x231.google.com [2607:f8b0:4003:c02::231])
        by mx.google.com with ESMTPS id g70si2522432yhd.243.2014.01.08.18.54.18
        for <std-proposals@isocpp.org>
        (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128);
        Wed, 08 Jan 2014 18:54:18 -0800 (PST)
Received-SPF: pass (google.com: domain of potswa@gmail.com designates 2607:f8b0:4003:c02::231 as permitted sender) client-ip=2607:f8b0:4003:c02::231;
Original-Received: by mail-oa0-f49.google.com with SMTP id n16so2750201oag.22
        for <std-proposals@isocpp.org>; Wed, 08 Jan 2014 18:54:17 -0800 (PST)
X-Received: by 10.182.60.233 with SMTP id k9mr474489obr.34.1389236057737;
        Wed, 08 Jan 2014 18:54:17 -0800 (PST)
Original-Received: from Davids-MacBook-Pro.local ([121.54.54.58])
        by mx.google.com with ESMTPSA id ii8sm3560677obb.11.2014.01.08.18.54.15
        for <std-proposals@isocpp.org>
        (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128);
        Wed, 08 Jan 2014 18:54:16 -0800 (PST)
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:24.0) Gecko/20100101 Thunderbird/24.2.0
In-Reply-To: <-9126987679220332623@gmail297201516>
X-Original-Sender: potswa@gmail.com
X-Original-Authentication-Results: mx.google.com;       spf=pass (google.com:
 domain of potswa@gmail.com designates 2607:f8b0:4003:c02::231 as permitted
 sender) smtp.mail=potswa@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:8480
Archived-At: <http://permalink.gmane.org/gmane.comp.lang.c++.isocpp.proposals/8480>

On 1/9/14 10:41 AM, Richard Smith wrote:
> On Wed Jan 08 2014 at 5:28:21 PM, David Krauss <potswa@gmail.com> wrote:
>
> It's not an overload, it's a partial specialization.

OK, that wasn't clear from the example. So do you intend that an=20
identifier declared with "?" never be used? What could you possibly do=20
with X?

Quoting the previous message:

>> I still don't see the value of an identifier, as opposed to a pack
>> expansion element, that can be either a type or a value. And such a name
>> would throw a wrench into template parsing. They could *only* be used as
>> explicit template arguments to functions as in my example above, or to
>> template template parameters with "?"-like parameter lists.

Edit: You couldn't even use X in these cases, because parse time=20
ambiguity of a template argument is always resolved in favor of a=20
typename ([temp.arg] =A714.3/2).

>> If you end up needing to use is_type, you're already in deep shit.
>>
>> On the other hand, parameter lists are already unpacked using
>> overloading, or partial specialization which works the same way. This
>> gives you a branching point to different code paths for type, value, or
>> template, which can already be written and parsed without redesigning
>> dependent name lookup.
>>
>> This is why I think "..." is sufficient with no motivation for "?" or
>> any provision for a single argument.
>>

--=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/.

.
