C++ Logo

std-proposals

Advanced search

Re: [std-proposals] Lambda type not isolated within function

From: Arthur O'Dwyer <arthur.j.odwyer_at_[hidden]>
Date: Thu, 20 Apr 2023 11:35:57 -0400
On Thu, Apr 20, 2023 at 11:28 AM Ville Voutilainen <
ville.voutilainen_at_[hidden]> wrote:

> On Thu, 20 Apr 2023 at 18:09, Arthur O'Dwyer <arthur.j.odwyer_at_[hidden]>
> wrote:
> > @Ville, I agree 100% with the "Why would we?" part, but I don't see what
> you mean about "new kind of lambda."
>
> Right now, you can declare two kinds of lambdas; ones that don't have
> captures, and ones that do. You can't declare
> a lambda that takes its captures as constructor arguments. So that
> would be a new kind of lambda.
>

Ah, okay. I had considered that "changing the semantics of one of the two
existing kinds," not "introducing a new kind and retiring one of the old
kinds," but I see. :)

–Arthur

Received on 2023-04-20 15:36:09