Mercurial > projects > ddmd
annotate dmd/TypeInfoInvariantDeclaration.d @ 174:af724d3510d7
lot os toCBuffer methods implemented
moved shared Type.* stuff into Global
author | korDen |
---|---|
date | Sun, 10 Oct 2010 03:47:23 +0400 |
parents | e28b18c23469 |
children | e3afd1303184 |
rev | line source |
---|---|
72 | 1 module dmd.TypeInfoInvariantDeclaration; |
2 | |
114 | 3 import dmd.common; |
72 | 4 import dmd.Type; |
174 | 5 import dmd.Global; |
72 | 6 import dmd.TypeInfoDeclaration; |
0 | 7 import dmd.backend.dt_t; |
8 import dmd.backend.Util; | |
72 | 9 import dmd.backend.TYM; |
10 | |
93
df6d0f967680
implemented a whole bunch of methods to make phobos 2.035 compile
Trass3r
parents:
73
diff
changeset
|
11 version(DMDV2) |
0 | 12 class TypeInfoInvariantDeclaration : TypeInfoDeclaration |
13 { | |
14 this(Type tinfo) | |
15 { | |
16 super(tinfo, 0); | |
174 | 17 type = global.typeinfoinvariant.type; |
0 | 18 } |
19 | |
72 | 20 override void toDt(dt_t** pdt) |
0 | 21 { |
22 //printf("TypeInfoInvariantDeclaration.toDt() %s\n", toChars()); | |
174 | 23 dtxoff(pdt, global.typeinfoinvariant.toVtblSymbol(), 0, TYnptr); // vtbl for TypeInfo_Invariant |
0 | 24 dtdword(pdt, 0); // monitor |
25 Type tm = tinfo.mutableOf(); | |
26 tm = tm.merge(); | |
27 tm.getTypeInfo(null); | |
28 dtxoff(pdt, tm.vtinfo.toSymbol(), 0, TYnptr); | |
29 } | |
30 } | |
31 |