Mercurial > projects > ddmd
comparison dmd/TypeInfoInvariantDeclaration.d @ 0:10317f0c89a5
Initial commit
author | korDen |
---|---|
date | Sat, 24 Oct 2009 08:42:06 +0400 |
parents | |
children | 2e2a5c3f943a |
comparison
equal
deleted
inserted
replaced
-1:000000000000 | 0:10317f0c89a5 |
---|---|
1 module dmd.TypeInfoInvariantDeclaration; | |
2 | |
3 import dmd.Type; | |
4 import dmd.TypeInfoDeclaration; | |
5 import dmd.backend.dt_t; | |
6 import dmd.backend.Util; | |
7 import dmd.backend.TYM; | |
8 | |
9 class TypeInfoInvariantDeclaration : TypeInfoDeclaration | |
10 { | |
11 this(Type tinfo) | |
12 { | |
13 super(tinfo, 0); | |
14 } | |
15 | |
16 void toDt(dt_t** pdt) | |
17 { | |
18 //printf("TypeInfoInvariantDeclaration.toDt() %s\n", toChars()); | |
19 dtxoff(pdt, Type.typeinfoinvariant.toVtblSymbol(), 0, TYnptr); // vtbl for TypeInfo_Invariant | |
20 dtdword(pdt, 0); // monitor | |
21 Type tm = tinfo.mutableOf(); | |
22 tm = tm.merge(); | |
23 tm.getTypeInfo(null); | |
24 dtxoff(pdt, tm.vtinfo.toSymbol(), 0, TYnptr); | |
25 } | |
26 } | |
27 |