comparison dmd/TypeSArray.d @ 126:1765f3ef917d

ClassDeclarations, Arguments -> Vector
author Eldar Insafutdinov <e.insafutdinov@gmail.com>
date Fri, 03 Sep 2010 23:25:55 +0100
parents 347de076ad34
children 60bb0fe4563e
comparison
equal deleted inserted replaced
125:767a01c2a272 126:1765f3ef917d
194 switch (tbn.ty) 194 switch (tbn.ty)
195 { 195 {
196 case TY.Ttuple: 196 case TY.Ttuple:
197 { // Index the tuple to get the type 197 { // Index the tuple to get the type
198 assert(dim); 198 assert(dim);
199 TypeTuple tt = cast(TypeTuple)tbn; 199 auto tt = cast(TypeTuple)tbn;
200 ulong d = dim.toUInteger(); 200 ulong d = dim.toUInteger();
201 201
202 if (d >= tt.arguments.dim) 202 if (d >= tt.arguments.dim)
203 { 203 {
204 error(loc, "tuple index %ju exceeds %u", d, tt.arguments.dim); 204 error(loc, "tuple index %ju exceeds %u", d, tt.arguments.dim);
205 return Type.terror; 205 return Type.terror;
206 } 206 }
207 Argument arg = cast(Argument)tt.arguments.data[cast(size_t)d]; 207 auto arg = tt.arguments[cast(size_t)d];
208 return arg.type; 208 return arg.type;
209 } 209 }
210 case TY.Tstruct: 210 case TY.Tstruct:
211 { TypeStruct ts = cast(TypeStruct)tbn; 211 { TypeStruct ts = cast(TypeStruct)tbn;
212 if (ts.sym.isnested) 212 if (ts.sym.isnested)