Mercurial > projects > ddmd
comparison dmd/TypeInfoDelegateDeclaration.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 |
comparison
equal
deleted
inserted
replaced
173:d237b38b5858 | 174:af724d3510d7 |
---|---|
3 import dmd.common; | 3 import dmd.common; |
4 import dmd.Type; | 4 import dmd.Type; |
5 import dmd.TypeInfoDeclaration; | 5 import dmd.TypeInfoDeclaration; |
6 import dmd.TypeDelegate; | 6 import dmd.TypeDelegate; |
7 import dmd.TY; | 7 import dmd.TY; |
8 import dmd.Global; | |
8 | 9 |
9 import dmd.backend.dt_t; | 10 import dmd.backend.dt_t; |
10 import dmd.backend.Util; | 11 import dmd.backend.Util; |
11 import dmd.backend.TYM; | 12 import dmd.backend.TYM; |
12 | 13 |
13 class TypeInfoDelegateDeclaration : TypeInfoDeclaration | 14 class TypeInfoDelegateDeclaration : TypeInfoDeclaration |
14 { | 15 { |
15 this(Type tinfo) | 16 this(Type tinfo) |
16 { | 17 { |
17 super(tinfo, 0); | 18 super(tinfo, 0); |
18 type = Type.typeinfodelegate.type; | 19 type = global.typeinfodelegate.type; |
19 } | 20 } |
20 | 21 |
21 override void toDt(dt_t** pdt) | 22 override void toDt(dt_t** pdt) |
22 { | 23 { |
23 //printf("TypeInfoDelegateDeclaration.toDt()\n"); | 24 //printf("TypeInfoDelegateDeclaration.toDt()\n"); |
24 dtxoff(pdt, Type.typeinfodelegate.toVtblSymbol(), 0, TYnptr); // vtbl for TypeInfo_Delegate | 25 dtxoff(pdt, global.typeinfodelegate.toVtblSymbol(), 0, TYnptr); // vtbl for TypeInfo_Delegate |
25 dtdword(pdt, 0); // monitor | 26 dtdword(pdt, 0); // monitor |
26 | 27 |
27 assert(tinfo.ty == Tdelegate); | 28 assert(tinfo.ty == Tdelegate); |
28 | 29 |
29 TypeDelegate tc = cast(TypeDelegate)tinfo; | 30 TypeDelegate tc = cast(TypeDelegate)tinfo; |