Function template as template parameter

Andrey Zherikov andrey.zherikov at gmail.com
Sun Dec 11 22:30:51 UTC 2022


On Sunday, 11 December 2022 at 16:24:30 UTC, Ali Çehreli wrote:
> On 12/11/22 05:54, Salih Dincer wrote:
> > On Sunday, 11 December 2022 at 09:43:34 UTC, Andrey Zherikov
> wrote:
> >> Note that callback parameter must be compile-time parameter
> as it
> >> represents a member of a type during introspection done by
> `foo`.
> >
> > I can't quite understand the question, this already works:
>
> I think the OP is trying to create an anonymous template.

Yes

> The following does not work when one attempts to use the 
> template anonymously. Just trying to pass a template just like 
> a lambda

Thanks for confirming this.


More information about the Digitalmars-d-learn mailing list