Mercurial > projects > ldc
diff gen/structs.h @ 705:5a2983f97498
Fixed weird struct problem from downs, see mini/compile_structs1.d
Rewrote DtoIndexStruct/Class , the old implementation were way too complex for what we really need now - since the DotVar changes.
author | Tomas Lindquist Olsen <tomas.l.olsen@gmail.com> |
---|---|
date | Tue, 14 Oct 2008 15:35:49 +0200 |
parents | 74101be2a553 |
children | 340acf1535d0 |
line wrap: on
line diff
--- a/gen/structs.h Tue Oct 14 13:21:14 2008 +0200 +++ b/gen/structs.h Tue Oct 14 15:35:49 2008 +0200 @@ -30,8 +30,8 @@ */ LLValue* DtoStructEquals(TOK op, DValue* lhs, DValue* rhs); -typedef LLSmallVector<unsigned, 3> DStructIndexVector; -LLValue* DtoIndexStruct(LLValue* ptr, StructDeclaration* sd, Type* t, unsigned os, DStructIndexVector& idxs); +// index a struct one level +LLValue* DtoIndexStruct(LLValue* src, StructDeclaration* sd, VarDeclaration* vd); struct DUnionField {