| Thread overview | |||||
|---|---|---|---|---|---|
|
April 08, 2013 Only partial type info for templated classes | ||||
|---|---|---|---|---|
| ||||
class C(T){}
class CC(T){}
struct S(T){}
struct SS(T){}
void main()
{
import std.stdio;
writeln(typeid(S!(SS!int)).name); // S!(SS!(int)).S
writeln(typeid(C!(CC!int)).name); // C!(CC).C
}
Is there a way to get the full type info in the name for a templated class (i.e. like the struct)?
| ||||
April 10, 2013 Re: Only partial type info for templated classes | ||||
|---|---|---|---|---|
| ||||
Posted in reply to cal | On Monday, 8 April 2013 at 05:12:24 UTC, cal wrote:
>
> class C(T){}
> class CC(T){}
>
> struct S(T){}
> struct SS(T){}
>
> void main()
> {
> import std.stdio;
> writeln(typeid(S!(SS!int)).name); // S!(SS!(int)).S
> writeln(typeid(C!(CC!int)).name); // C!(CC).C
> }
>
> Is there a way to get the full type info in the name for a templated class (i.e. like the struct)?
File a bug? Not sure if it is expected.
| |||
April 10, 2013 Re: Only partial type info for templated classes | ||||
|---|---|---|---|---|
| ||||
Posted in reply to Jesse Phillips | On Wednesday, 10 April 2013 at 18:24:58 UTC, Jesse Phillips wrote:
> On Monday, 8 April 2013 at 05:12:24 UTC, cal wrote:
>>
>> class C(T){}
>> class CC(T){}
>>
>> struct S(T){}
>> struct SS(T){}
>>
>> void main()
>> {
>> import std.stdio;
>> writeln(typeid(S!(SS!int)).name); // S!(SS!(int)).S
>> writeln(typeid(C!(CC!int)).name); // C!(CC).C
>> }
>>
>> Is there a way to get the full type info in the name for a templated class (i.e. like the struct)?
>
> File a bug? Not sure if it is expected.
Yeh filed as enhancement as I wasn't sure either
| |||
Copyright © 1999-2021 by the D Language Foundation
Permalink
Reply