Why type specialization is defined differently than is expression type specialization ?

Timon Gehr timon.gehr at gmx.ch
Wed Jun 27 12:23:07 PDT 2012


On 06/27/2012 08:21 PM, Alex Rønne Petersen wrote:
> On 27-06-2012 19:13, Timon Gehr wrote:
>> On 06/27/2012 03:56 PM, deadalnix wrote:
>>> All is in the title.
>>>
>>> I can do is(T : class) but not template(T : class) . Is this intended or
>>> is it because it is ?
>>
>> You cannot do is(T : class).
>
> I think what's really worrying is that this is legal:
>
> void foo(T : class)()
> {
> }
>

This is not legal.

> But this is not:
>
> template Foo(T : class)
> {
> }
>



More information about the Digitalmars-d mailing list