On Mon, 14 Jun 2021 15:12:37 +0200
"Alf P. Steinbach" <
alf.p.s...@gmail.com> wrote:
>On 14 Jun 2021 13:10, Bonita Montero wrote:
>> int main()
>> {
>> auto f = []<typename T>() -> T
>> {
>> return 123;
>> };
>> f.operator ()<int>(); // only way ?
>> }
>>
>> Is the above code the only way to call the lambda ?
>
>I've never used a templated lambda, but if I needed something like that
>I think I'd use a type-indicating argument, like (off the cuff)
>
> template< class T > struct Use_type_{ using Type = T; };
>
> auto main() -> int