220 37727 <CANh8DEk7X8whB5K5GNQai2r9gt52HKEVtxE6aGy78w_+p20BTQ@mail.gmail.com> article
Path: news.gmane.org!.POSTED!not-for-mail
From: "'Matt Calabrese' via ISO C++ Standard - Future Proposals" <std-proposals@isocpp.org>
Newsgroups: gmane.comp.lang.c++.isocpp.proposals
Subject: Re: Generic function-wrapper object
Date: Mon, 09 Apr 2018 15:46:30 +0000
Lines: 180
Approved: news@gmane.org
Message-ID: <CANh8DEk7X8whB5K5GNQai2r9gt52HKEVtxE6aGy78w_+p20BTQ@mail.gmail.com>
References: <e2229872-0c8a-4673-b452-602959fc938f@isocpp.org>
Reply-To: std-proposals@isocpp.org
NNTP-Posting-Host: blaine.gmane.org
Mime-Version: 1.0
Content-Type: multipart/alternative; boundary="94eb2c05b49ee859d905696c4f42"
X-Trace: blaine.gmane.org 1523288679 17911 195.159.176.226 (9 Apr 2018 15:44:39 GMT)
X-Complaints-To: usenet@blaine.gmane.org
NNTP-Posting-Date: Mon, 9 Apr 2018 15:44:39 +0000 (UTC)
To: "ISO C++ Standard - Future Proposals" <std-proposals@isocpp.org>
Original-X-From: std-proposals+bncBCGNLO5F34OBBYUVV3LAKGQEZVRD22A@isocpp.org Mon Apr 09 17:44:35 2018
Return-path: <std-proposals+bncBCGNLO5F34OBBYUVV3LAKGQEZVRD22A@isocpp.org>
Envelope-to: gclcip-std-proposals@m.gmane.org
Original-Received: from mail-io0-f197.google.com ([209.85.223.197])
	by blaine.gmane.org with esmtp (Exim 4.84_2)
	(envelope-from <std-proposals+bncBCGNLO5F34OBBYUVV3LAKGQEZVRD22A@isocpp.org>)
	id 1f5YyA-0004Xp-FN
	for gclcip-std-proposals@m.gmane.org; Mon, 09 Apr 2018 17:44:34 +0200
Original-Received: by mail-io0-f197.google.com with SMTP id j3sf2722626ioe.13
        for <gclcip-std-proposals@m.gmane.org>; Mon, 09 Apr 2018 08:46:44 -0700 (PDT)
ARC-Seal: i=2; a=rsa-sha256; t=1523288804; cv=pass;
        d=google.com; s=arc-20160816;
        b=uajs8H33plZ8X4/E2NnRJsziXR32ZYTkV0W3AFXMVJhr10SbWcd/3MrYhSHrOKZdow
         YsaSpIz6RWksmj05WcCeH7/6U/2WFBpd6DDo9hhrdr9fgV1BN5U1WyfPKqYfoeNWyUTz
         a+3wC72mI8+0HRLT/Eh3/Rsn9YJKkdjfeo23cN4XzkfLTeoFEXR5cfzeYrZIPjoo68wY
         bVNZhAKKpZx0cM6vJErFRKhVSW9qs/PUahkseuPLV6RVO4fAhZfUVwUxmYlB8UXAXj9Z
         Bsk/1iD9+d2h6nAOkETLmoPQBk4cy2dlhcEy8W32oNhdQ/7JQYi5F9+6yp6v4iOHf1mH
         GZSg==
ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816;
        h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post
         :list-id:mailing-list:precedence:reply-to:to:subject:message-id:date
         :from:in-reply-to:references:mime-version:arc-authentication-results
         :arc-message-signature:dkim-signature:arc-authentication-results;
        bh=YH6ynoZlrwPpTCPYVo/9pcdGWzYq2TPSoPLbiHUYTp0=;
        b=UOsBnN/TyVDWjzZ17r0MVZQTa4ttnXgJ7aPUcJVXVlANCAzFq2y2na2MZ9ERfFvVL5
         2eVh6rlK0UJuObEpuB9JBr3Fm88KrGoCJTxhvZFq7potJODMEWO4tMABqn3GC/0VMZEn
         1Tm/ZF0+oeROsjYc0Gs2eJSNdk9fiIDSSbNpLMuXpZiB7VoIL5fixnhhuRY5kj8zlZ7x
         Eg0ZMZUnh8OwKKO89Vt6eg4Ca59CUj6mwUoffLgvP+5KQkzmSCMi658pQib84auwP0Na
         rt2qLdbR1DVXPNl92t3+bqg3RJKb0xUdBHwWUuVBydwbUTVNBCKhlw5lmiN1inU35dD6
         6Xpg==
ARC-Authentication-Results: i=2; mx.google.com;
       dkim=pass header.i=@google.com header.s=20161025 header.b=rq5MJfnp;
       spf=pass (google.com: domain of calabrese@google.com designates 209.85.220.41 as permitted sender) smtp.mailfrom=calabrese@google.com;
       dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=isocpp-org.20150623.gappssmtp.com; s=20150623;
        h=mime-version:references:in-reply-to: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;
        bh=YH6ynoZlrwPpTCPYVo/9pcdGWzYq2TPSoPLbiHUYTp0=;
        b=g+waiVYZAykc4u7bZRVyOEeWOkdycsQMC23C9FAmEDi9YnE0/gIuSdOtH9AkATpgGS
         b2bc26DOKlc602NSA1iM8WG1ybWv0nhMWNMfE7jtsZf4fn701mknJ4V8XS3GbqkZSJYR
         0dcup9UTrW2HWKzDFdUjYevF0WEHeCQqXMzGIvoIxp5ucDMB+XqA0d/5GGEd5XTCI1yk
         yXM9TOtQ20TeX5o42WUrLNfmqfE/Hzw4UajM8Lc1zZYvNTujPXDAyR0u96hnbHeUktoB
         eXb2V06H6Bax4tTjXIrV/RNy7NITvaXlHWSFUTVTE0J4BrUxmkMzZohLW3qofWqL3W9Z
         hwig==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=1e100.net; s=20161025;
        h=x-gm-message-state:mime-version:references:in-reply-to:from:date
         :message-id:subject:to:x-original-sender
         :x-original-authentication-results:reply-to:precedence:mailing-list
         :list-id:x-spam-checked-in-group:list-post:list-help:list-archive
         :list-subscribe:list-unsubscribe;
        bh=YH6ynoZlrwPpTCPYVo/9pcdGWzYq2TPSoPLbiHUYTp0=;
        b=k1AzHLPRusrhQ/hZdn2IfFCarUhTTRMrSSCt2K7FiJLvIBCjf3Ls5uS8zZ+Nnn2fKT
         vQD+8LcYRgYFhpmnToxQMBsno8E8jLs9MQ5cs16+NXCKaSC5qrJLlUgKSId6mp98fdRv
         dlw0jabz7wDwEBb6b1QuU8dvB3CSBQGs+emNfJN+KLpmsL9HQuUUpghFqg6UzhI7YHHw
         s4MlterNXtsCipoFyaokEzkGZz8t/S07mrCcAgsbIH5CyKC6Cat4JNiz0zij7qT06McR
         pzVClSq4wWcfBzDRqzAYKxC4N57WF2oTocf/leEmFcPitSMT6N4etkaY8JoS2aEnWUl7
         zpSw==
X-Gm-Message-State: ALQs6tA2LGmPEvOqYjMj7uYJ5gnrCuZ9IRulcQz1EP3a4+9bwufY6Euj
	TBJaYlkKYmiLBVTE7FYUpYk=
X-Google-Smtp-Source: AIpwx49rKe2/8h2TDYY3GpV4LKsyqDPJB7GQruV7pp6JG9a8Ps5pdWn8kuUQui/ghqXbrCKq6020oA==
X-Received: by 2002:a24:6952:: with SMTP id e79-v6mr242228itc.56.1523288803936;
        Mon, 09 Apr 2018 08:46:43 -0700 (PDT)
X-BeenThere: std-proposals@isocpp.org
Original-Received: by 2002:a24:d246:: with SMTP id z67-v6ls1589081itf.7.canary-gmail;
 Mon, 09 Apr 2018 08:46:42 -0700 (PDT)
X-Received: by 2002:a24:1301:: with SMTP id 1-v6mr517948itz.99.1523288802581;
        Mon, 09 Apr 2018 08:46:42 -0700 (PDT)
ARC-Seal: i=1; a=rsa-sha256; t=1523288802; cv=none;
        d=google.com; s=arc-20160816;
        b=t/zyQM01+gopbObBgPGGB424m9rd1KDtqTGKlHtyT15AD679jZJkgcvgHx3jdUcxu7
         4PyKhF+8k/HH9K4TIODvQScclQ7Xjat0dhZyRo8wjNDqYnj2oVie5hP83Adj060e4xxr
         MrB+6KWRrQILoM/EPooS6V5lEeGl7EMquNoYT/0bdmUCrnn+9LX3JLHO6jin/GT5ndiw
         11C3x+JbkUY+97rxq5vjMsMa37r73uNsBPxAAAGnOa/PtZ56BUNTIA0oPb+ltBIn/k4i
         aQvnMAvfJABFhVTxWFbLXL7+terbu2HgIGK+OhhwDyBfk6vUY4NdfW4/qQnND2jvOiUC
         8mZQ==
ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816;
        h=to:subject:message-id:date:from:in-reply-to:references:mime-version
         :dkim-signature:arc-authentication-results;
        bh=JJEZfliecAdHfOk2RKUCyFwjDdflZLsxmkSrdxPPBgo=;
        b=pUUglqAXKX77aFsUv2eYAd+XzWZ1SUaniQF/ZfO0OWh2sHYSSHJ6lhKrcGZM3PGYIk
         vq12aWg+DdRrmTha/Bd8qUDZB9u2MNP+lMGYipXpp0b4AJfq3By6iR74RSy8CcSj9Kla
         kFFMo2OWRLz+Px7wUqwYblvM411gQDXpEDj1xXTp9cjVQKFuZqM1esw1lUnh5pjl7vKA
         +Fw1n7ajmaIYyww5hgZFHb5zZMSMJ8G2fymBFwuaaIqtnn/mhkVtgWOh6EkwzQfpBZ6w
         mDn9Rspe3JU4QQN/7thPJI3VHgcmA9srt7jMteOWhO7TAkA4ssRKHt/cUKoqvHIIBqfW
         dpLQ==
ARC-Authentication-Results: i=1; mx.google.com;
       dkim=pass header.i=@google.com header.s=20161025 header.b=rq5MJfnp;
       spf=pass (google.com: domain of calabrese@google.com designates 209.85.220.41 as permitted sender) smtp.mailfrom=calabrese@google.com;
       dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com
Original-Received: from mail-sor-f41.google.com (mail-sor-f41.google.com. [209.85.220.41])
        by mx.google.com with SMTPS id v98sor333623iov.37.2018.04.09.08.46.42
        for <std-proposals@isocpp.org>
        (Google Transport Security);
        Mon, 09 Apr 2018 08:46:42 -0700 (PDT)
Received-SPF: pass (google.com: domain of calabrese@google.com designates 209.85.220.41 as permitted sender) client-ip=209.85.220.41;
X-Received: by 10.107.171.194 with SMTP id u185mr32884101ioe.234.1523288801504;
 Mon, 09 Apr 2018 08:46:41 -0700 (PDT)
In-Reply-To: <e2229872-0c8a-4673-b452-602959fc938f@isocpp.org>
X-Original-Sender: calabrese@google.com
X-Original-Authentication-Results: mx.google.com;       dkim=pass
 header.i=@google.com header.s=20161025 header.b=rq5MJfnp;       spf=pass
 (google.com: domain of calabrese@google.com designates 209.85.220.41 as
 permitted sender) smtp.mailfrom=calabrese@google.com;       dmarc=pass
 (p=REJECT sp=REJECT dis=NONE) header.from=google.com
X-Original-From: Matt Calabrese <calabrese@google.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:37727
Archived-At: <http://permalink.gmane.org/gmane.comp.lang.c++.isocpp.proposals/37727>

--94eb2c05b49ee859d905696c4f42
Content-Type: text/plain; charset="UTF-8"

On Mon, Apr 9, 2018 at 11:36 AM Hamza Sood <hamza_sood@me.com> wrote:

> I propose the inclusion of a function object (somewhat similar to the
> deprecated ptr_fun) that looks something like:
>
> template<auto f>
> requires is_pointer_v<decltype(f)> &&
>          is_function_v<remove_pointer_t<decltype(f)>>
> struct func_ptr {
>   template<typename... Args>
>   decltype(auto) operator()(Args&&... args) noexcept(noexcept(f(forward<
> Args>(args)...))) {
>     return f(forward<Args>(args)...);
>   }
> };
>
> The main difference with ptr_fun being that the function pointer is part
> of the type.
>


I have proposed something like that here: http://wg21.link/p0477

It is awaiting a revision with some different names, and I will need to
update it to target C++20 (updated constraints, etc.).

-- Matt Calabrese

-- 
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/CANh8DEk7X8whB5K5GNQai2r9gt52HKEVtxE6aGy78w_%2Bp20BTQ%40mail.gmail.com.

--94eb2c05b49ee859d905696c4f42
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr"><br><div class=3D"gmail_quote"><div dir=3D"ltr">On Mon, Ap=
r 9, 2018 at 11:36 AM Hamza Sood &lt;<a href=3D"mailto:hamza_sood@me.com">h=
amza_sood@me.com</a>&gt; wrote:<br></div><blockquote class=3D"gmail_quote" =
style=3D"margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);pa=
dding-left:1ex"><div dir=3D"ltr">I propose the inclusion of a function obje=
ct (somewhat similar to the deprecated ptr_fun) that looks something like:<=
div><br><div><div class=3D"gmail-m_-767131349022434533prettyprint" style=3D=
"background-color:rgb(250,250,250);border:1px solid rgb(187,187,187);word-w=
rap:break-word"><code class=3D"gmail-m_-767131349022434533prettyprint"><div=
 class=3D"gmail-m_-767131349022434533subprettyprint"><span style=3D"color:r=
gb(0,0,136)" class=3D"gmail-m_-767131349022434533styled-by-prettify">templa=
te</span><span style=3D"color:rgb(102,102,0)" class=3D"gmail-m_-76713134902=
2434533styled-by-prettify">&lt;</span><span style=3D"color:rgb(0,0,136)" cl=
ass=3D"gmail-m_-767131349022434533styled-by-prettify">auto</span><span styl=
e=3D"color:rgb(0,0,0)" class=3D"gmail-m_-767131349022434533styled-by-pretti=
fy"> f</span><span style=3D"color:rgb(102,102,0)" class=3D"gmail-m_-7671313=
49022434533styled-by-prettify">&gt;</span><span style=3D"color:rgb(0,0,0)" =
class=3D"gmail-m_-767131349022434533styled-by-prettify"><br>requires is_poi=
nter_v</span><span style=3D"color:rgb(102,102,0)" class=3D"gmail-m_-7671313=
49022434533styled-by-prettify">&lt;</span><span style=3D"color:rgb(0,0,136)=
" class=3D"gmail-m_-767131349022434533styled-by-prettify">decltype</span><s=
pan style=3D"color:rgb(102,102,0)" class=3D"gmail-m_-767131349022434533styl=
ed-by-prettify">(</span><span style=3D"color:rgb(0,0,0)" class=3D"gmail-m_-=
767131349022434533styled-by-prettify">f</span><span style=3D"color:rgb(102,=
102,0)" class=3D"gmail-m_-767131349022434533styled-by-prettify">)&gt;</span=
><span style=3D"color:rgb(0,0,0)" class=3D"gmail-m_-767131349022434533style=
d-by-prettify"> </span><span style=3D"color:rgb(102,102,0)" class=3D"gmail-=
m_-767131349022434533styled-by-prettify">&amp;&amp;</span><span style=3D"co=
lor:rgb(0,0,0)" class=3D"gmail-m_-767131349022434533styled-by-prettify"><br=
>=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0is_function_v</span><span style=3D"color=
:rgb(102,102,0)" class=3D"gmail-m_-767131349022434533styled-by-prettify">&l=
t;</span><span style=3D"color:rgb(0,0,0)" class=3D"gmail-m_-767131349022434=
533styled-by-prettify">remove_pointer_t</span><span style=3D"color:rgb(102,=
102,0)" class=3D"gmail-m_-767131349022434533styled-by-prettify">&lt;</span>=
<span style=3D"color:rgb(0,0,136)" class=3D"gmail-m_-767131349022434533styl=
ed-by-prettify">decltype</span><span style=3D"color:rgb(102,102,0)" class=
=3D"gmail-m_-767131349022434533styled-by-prettify">(</span><span style=3D"c=
olor:rgb(0,0,0)" class=3D"gmail-m_-767131349022434533styled-by-prettify">f<=
/span><span style=3D"color:rgb(102,102,0)" class=3D"gmail-m_-76713134902243=
4533styled-by-prettify">)&gt;&gt;</span><span style=3D"color:rgb(0,0,0)" cl=
ass=3D"gmail-m_-767131349022434533styled-by-prettify"><br></span><span styl=
e=3D"color:rgb(0,0,136)" class=3D"gmail-m_-767131349022434533styled-by-pret=
tify">struct</span><span style=3D"color:rgb(0,0,0)" class=3D"gmail-m_-76713=
1349022434533styled-by-prettify"> func_ptr </span><span style=3D"color:rgb(=
102,102,0)" class=3D"gmail-m_-767131349022434533styled-by-prettify">{</span=
><span style=3D"color:rgb(0,0,0)" class=3D"gmail-m_-767131349022434533style=
d-by-prettify"><br>=C2=A0 </span><span style=3D"color:rgb(0,0,136)" class=
=3D"gmail-m_-767131349022434533styled-by-prettify">template</span><span sty=
le=3D"color:rgb(102,102,0)" class=3D"gmail-m_-767131349022434533styled-by-p=
rettify">&lt;</span><span style=3D"color:rgb(0,0,136)" class=3D"gmail-m_-76=
7131349022434533styled-by-prettify">typename</span><span style=3D"color:rgb=
(102,102,0)" class=3D"gmail-m_-767131349022434533styled-by-prettify">...</s=
pan><span style=3D"color:rgb(0,0,0)" class=3D"gmail-m_-767131349022434533st=
yled-by-prettify"> </span><span style=3D"color:rgb(102,0,102)" class=3D"gma=
il-m_-767131349022434533styled-by-prettify">Args</span><span style=3D"color=
:rgb(102,102,0)" class=3D"gmail-m_-767131349022434533styled-by-prettify">&g=
t;</span><span style=3D"color:rgb(0,0,0)" class=3D"gmail-m_-767131349022434=
533styled-by-prettify"><br>=C2=A0 </span><span style=3D"color:rgb(0,0,136)"=
 class=3D"gmail-m_-767131349022434533styled-by-prettify">decltype</span><sp=
an style=3D"color:rgb(102,102,0)" class=3D"gmail-m_-767131349022434533style=
d-by-prettify">(</span><span style=3D"color:rgb(0,0,136)" class=3D"gmail-m_=
-767131349022434533styled-by-prettify">auto</span><span style=3D"color:rgb(=
102,102,0)" class=3D"gmail-m_-767131349022434533styled-by-prettify">)</span=
><span style=3D"color:rgb(0,0,0)" class=3D"gmail-m_-767131349022434533style=
d-by-prettify"> </span><span style=3D"color:rgb(0,0,136)" class=3D"gmail-m_=
-767131349022434533styled-by-prettify">operator</span><span style=3D"color:=
rgb(102,102,0)" class=3D"gmail-m_-767131349022434533styled-by-prettify">()(=
</span><span style=3D"color:rgb(102,0,102)" class=3D"gmail-m_-7671313490224=
34533styled-by-prettify">Args</span><span style=3D"color:rgb(102,102,0)" cl=
ass=3D"gmail-m_-767131349022434533styled-by-prettify">&amp;&amp;...</span><=
span style=3D"color:rgb(0,0,0)" class=3D"gmail-m_-767131349022434533styled-=
by-prettify"> args</span><span style=3D"color:rgb(102,102,0)" class=3D"gmai=
l-m_-767131349022434533styled-by-prettify">)</span><span style=3D"color:rgb=
(0,0,0)" class=3D"gmail-m_-767131349022434533styled-by-prettify"> noexcept<=
/span><span style=3D"color:rgb(102,102,0)" class=3D"gmail-m_-76713134902243=
4533styled-by-prettify">(</span><span style=3D"color:rgb(0,0,0)" class=3D"g=
mail-m_-767131349022434533styled-by-prettify">noexcept</span><span style=3D=
"color:rgb(102,102,0)" class=3D"gmail-m_-767131349022434533styled-by-pretti=
fy">(</span><span style=3D"color:rgb(0,0,0)" class=3D"gmail-m_-767131349022=
434533styled-by-prettify">f</span><span style=3D"color:rgb(102,102,0)" clas=
s=3D"gmail-m_-767131349022434533styled-by-prettify">(</span><font color=3D"=
#000000"><span style=3D"color:rgb(0,0,0)" class=3D"gmail-m_-767131349022434=
533styled-by-prettify">forward</span><span style=3D"color:rgb(102,102,0)" c=
lass=3D"gmail-m_-767131349022434533styled-by-prettify">&lt;</span><span sty=
le=3D"color:rgb(102,0,102)" class=3D"gmail-m_-767131349022434533styled-by-p=
rettify">Args</span><span style=3D"color:rgb(102,102,0)" class=3D"gmail-m_-=
767131349022434533styled-by-prettify">&gt;(</span><span style=3D"color:rgb(=
0,0,0)" class=3D"gmail-m_-767131349022434533styled-by-prettify">args</span>=
<span style=3D"color:rgb(102,102,0)" class=3D"gmail-m_-767131349022434533st=
yled-by-prettify">)...</span></font><span style=3D"color:rgb(102,102,0)" cl=
ass=3D"gmail-m_-767131349022434533styled-by-prettify">)))</span><span style=
=3D"color:rgb(0,0,0)" class=3D"gmail-m_-767131349022434533styled-by-prettif=
y"> </span><span style=3D"color:rgb(102,102,0)" class=3D"gmail-m_-767131349=
022434533styled-by-prettify">{</span><span style=3D"color:rgb(0,0,0)" class=
=3D"gmail-m_-767131349022434533styled-by-prettify"><br>=C2=A0 =C2=A0 </span=
><span style=3D"color:rgb(0,0,136)" class=3D"gmail-m_-767131349022434533sty=
led-by-prettify">return</span><span style=3D"color:rgb(0,0,0)" class=3D"gma=
il-m_-767131349022434533styled-by-prettify"> f</span><span style=3D"color:r=
gb(102,102,0)" class=3D"gmail-m_-767131349022434533styled-by-prettify">(</s=
pan><span style=3D"color:rgb(0,0,0)" class=3D"gmail-m_-767131349022434533st=
yled-by-prettify">forward</span><span style=3D"color:rgb(102,102,0)" class=
=3D"gmail-m_-767131349022434533styled-by-prettify">&lt;</span><span style=
=3D"color:rgb(102,0,102)" class=3D"gmail-m_-767131349022434533styled-by-pre=
ttify">Args</span><span style=3D"color:rgb(102,102,0)" class=3D"gmail-m_-76=
7131349022434533styled-by-prettify">&gt;(</span><span style=3D"color:rgb(0,=
0,0)" class=3D"gmail-m_-767131349022434533styled-by-prettify">args</span><s=
pan style=3D"color:rgb(102,102,0)" class=3D"gmail-m_-767131349022434533styl=
ed-by-prettify">)...);</span><span style=3D"color:rgb(0,0,0)" class=3D"gmai=
l-m_-767131349022434533styled-by-prettify"><br>=C2=A0 </span><span style=3D=
"color:rgb(102,102,0)" class=3D"gmail-m_-767131349022434533styled-by-pretti=
fy">}</span><span style=3D"color:rgb(0,0,0)" class=3D"gmail-m_-767131349022=
434533styled-by-prettify"><br></span><span style=3D"color:rgb(102,102,0)" c=
lass=3D"gmail-m_-767131349022434533styled-by-prettify">};</span></div></cod=
e></div><br>The main difference with ptr_fun being that the function pointe=
r is part of the type.</div></div></div></blockquote><div><br></div><div><b=
r></div><div>I have proposed something like that here:=C2=A0<a href=3D"http=
://wg21.link/p0477">http://wg21.link/p0477</a></div><div><br></div><div>It =
is awaiting a revision with some different names, and I will need to update=
 it to target C++20 (updated constraints, etc.).</div><div><br></div><div>-=
- Matt Calabrese</div></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/CANh8DEk7X8whB5K5GNQai2r9gt52HKEVtxE6=
aGy78w_%2Bp20BTQ%40mail.gmail.com?utm_medium=3Demail&utm_source=3Dfooter">h=
ttps://groups.google.com/a/isocpp.org/d/msgid/std-proposals/CANh8DEk7X8whB5=
K5GNQai2r9gt52HKEVtxE6aGy78w_%2Bp20BTQ%40mail.gmail.com</a>.<br />

--94eb2c05b49ee859d905696c4f42--

.
