C++ Logo

std-discussion

Advanced search

Re: Templatized virtual functions

From: Thiago Macieira <thiago_at_[hidden]>
Date: Wed, 24 Apr 2019 19:07:11 -0700
On Wednesday, 24 April 2019 09:16:50 PDT Ritwik Das via Std-Discussion wrote:
> So why would explicit instantiation of function templates work in this case:
>
> class Base
> {
> template<typename T>
> virtual int func() = 0;
> };

Because they wouldn't. The code above does not compile.

-- 
Thiago Macieira - thiago (AT) macieira.info - thiago (AT) kde.org
   Software Architect - Intel System Software Products

Received on 2019-04-24 21:08:51