Mercurial > projects > ddmd
comparison dmd/TypeInfoArrayDeclaration.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.TypeInfoArrayDeclaration; | |
2 | |
3 import dmd.Type; | |
4 import dmd.TypeInfoDeclaration; | |
5 import dmd.Type; | |
6 import dmd.TY; | |
7 import dmd.TypeDArray; | |
8 | |
9 import dmd.backend.dt_t; | |
10 import dmd.backend.Util; | |
11 import dmd.backend.TYM; | |
12 | |
13 class TypeInfoArrayDeclaration : TypeInfoDeclaration | |
14 { | |
15 this(Type tinfo) | |
16 { | |
17 super(tinfo, 0); | |
18 } | |
19 | |
20 void toDt(dt_t** pdt) | |
21 { | |
22 //printf("TypeInfoArrayDeclaration::toDt()\n"); | |
23 dtxoff(pdt, Type.typeinfoarray.toVtblSymbol(), 0, TYnptr); // vtbl for TypeInfo_Array | |
24 dtdword(pdt, 0); // monitor | |
25 | |
26 assert(tinfo.ty == Tarray); | |
27 | |
28 TypeDArray tc = cast(TypeDArray)tinfo; | |
29 | |
30 tc.next.getTypeInfo(null); | |
31 dtxoff(pdt, tc.next.vtinfo.toSymbol(), 0, TYnptr); // TypeInfo for array of type | |
32 } | |
33 } | |
34 |