C++ Logo

std-proposals

Advanced search

Re: [std-proposals] Callsite passed as template parameter

From: Thiago Macieira <thiago_at_[hidden]>
Date: Wed, 15 Nov 2023 07:44:50 -0800
On Wednesday, 15 November 2023 05:45:39 PST Frederick Virchanza Gotham via
Std-Proposals wrote:
> What I'm saying is: When the
> compiler encounters:
>
> template<typename = decltype([]{})>
>
> Is the compiler free to have one global lambda type that is shared as
> a default template parameter among all the instantiations?

It is not. The type must be different on every distinct instantiation.

-- 
Thiago Macieira - thiago (AT) macieira.info - thiago (AT) kde.org
   Software Architect - Intel DCAI Cloud Engineering

Received on 2023-11-15 15:44:52