Mercurial > projects > ldc
comparison dmd2/attrib.c @ 797:340acf1535d0
Removed KDevelop3 project files, CMake can generate them just fine!
Fixed function literals in static initializers.
Changed alignment of delegates from 2*PTRSIZE to just PTRSIZE.
Changed errors to go to stderr instead of stdout.
Fairly major rewriting of struct/union/class handling, STILL A BIT BUGGY !!!
author | Tomas Lindquist Olsen <tomas.l.olsen@gmail.com> |
---|---|
date | Sat, 29 Nov 2008 21:25:43 +0100 |
parents | f04dde6e882c |
children | 7d16ce7ad19d |
comparison
equal
deleted
inserted
replaced
796:6e7a4c3b64d2 | 797:340acf1535d0 |
---|---|
627 sc->inunion = isunion; | 627 sc->inunion = isunion; |
628 sc->offset = 0; | 628 sc->offset = 0; |
629 sc->flags = 0; | 629 sc->flags = 0; |
630 aad.structalign = sc->structalign; | 630 aad.structalign = sc->structalign; |
631 aad.parent = ad; | 631 aad.parent = ad; |
632 | |
633 for (unsigned i = 0; i < decl->dim; i++) | 632 for (unsigned i = 0; i < decl->dim; i++) |
634 { | 633 { |
635 Dsymbol *s = (Dsymbol *)decl->data[i]; | 634 Dsymbol *s = (Dsymbol *)decl->data[i]; |
636 | 635 |
637 s->semantic(sc); | 636 s->semantic(sc); |
682 // Add members of aad to ad | 681 // Add members of aad to ad |
683 //printf("\tadding members of aad (%p) to '%s'\n", &aad, ad->toChars()); | 682 //printf("\tadding members of aad (%p) to '%s'\n", &aad, ad->toChars()); |
684 for (unsigned i = 0; i < aad.fields.dim; i++) | 683 for (unsigned i = 0; i < aad.fields.dim; i++) |
685 { | 684 { |
686 VarDeclaration *v = (VarDeclaration *)aad.fields.data[i]; | 685 VarDeclaration *v = (VarDeclaration *)aad.fields.data[i]; |
686 | |
687 // LDC | |
688 v->offset2 = sc->offset; | |
687 | 689 |
688 v->offset += sc->offset; | 690 v->offset += sc->offset; |
689 | 691 |
690 // LDC | 692 // LDC |
691 if (!v->anonDecl) | 693 if (!v->anonDecl) |