Mercurial > projects > ldc
comparison dmd2/attrib.h @ 1526:54b3c1394d62
Merged dmdfe 2.031.
author | Robert Clipsham <robert@octarineparrot.com> |
---|---|
date | Tue, 07 Jul 2009 02:26:11 +0100 |
parents | 638d16625da2 |
children | e4f7b5d9c68a |
comparison
equal
deleted
inserted
replaced
1525:d28cd7c45267 | 1526:54b3c1394d62 |
---|---|
1 | 1 |
2 // Compiler implementation of the D programming language | 2 // Compiler implementation of the D programming language |
3 // Copyright (c) 1999-2007 by Digital Mars | 3 // Copyright (c) 1999-2009 by Digital Mars |
4 // All Rights Reserved | 4 // All Rights Reserved |
5 // written by Walter Bright | 5 // written by Walter Bright |
6 // http://www.digitalmars.com | 6 // http://www.digitalmars.com |
7 // License for redistribution is by either the Artistic License | 7 // License for redistribution is by either the Artistic License |
8 // in artistic.txt, or the GNU General Public License in gnu.txt. | 8 // in artistic.txt, or the GNU General Public License in gnu.txt. |
34 Array *decl; // array of Dsymbol's | 34 Array *decl; // array of Dsymbol's |
35 | 35 |
36 AttribDeclaration(Array *decl); | 36 AttribDeclaration(Array *decl); |
37 virtual Array *include(Scope *sc, ScopeDsymbol *s); | 37 virtual Array *include(Scope *sc, ScopeDsymbol *s); |
38 int addMember(Scope *sc, ScopeDsymbol *s, int memnum); | 38 int addMember(Scope *sc, ScopeDsymbol *s, int memnum); |
39 void semanticNewSc(Scope *sc, | |
40 unsigned newstc, enum LINK linkage, enum PROT protection, int explictProtection, | |
41 unsigned structalign); | |
39 void semantic(Scope *sc); | 42 void semantic(Scope *sc); |
40 void semantic2(Scope *sc); | 43 void semantic2(Scope *sc); |
41 void semantic3(Scope *sc); | 44 void semantic3(Scope *sc); |
42 void inlineScan(); | 45 void inlineScan(); |
43 void addComment(unsigned char *comment); | 46 void addComment(unsigned char *comment); |
90 | 93 |
91 ProtDeclaration(enum PROT p, Array *decl); | 94 ProtDeclaration(enum PROT p, Array *decl); |
92 Dsymbol *syntaxCopy(Dsymbol *s); | 95 Dsymbol *syntaxCopy(Dsymbol *s); |
93 void semantic(Scope *sc); | 96 void semantic(Scope *sc); |
94 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); | 97 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); |
98 | |
99 static void protectionToCBuffer(OutBuffer *buf, enum PROT protection); | |
95 }; | 100 }; |
96 | 101 |
97 struct AlignDeclaration : AttribDeclaration | 102 struct AlignDeclaration : AttribDeclaration |
98 { | 103 { |
99 unsigned salign; | 104 unsigned salign; |
105 }; | 110 }; |
106 | 111 |
107 struct AnonDeclaration : AttribDeclaration | 112 struct AnonDeclaration : AttribDeclaration |
108 { | 113 { |
109 int isunion; | 114 int isunion; |
110 Scope *scope; // !=NULL means context to use | |
111 int sem; // 1 if successful semantic() | 115 int sem; // 1 if successful semantic() |
112 | 116 |
113 AnonDeclaration(Loc loc, int isunion, Array *decl); | 117 AnonDeclaration(Loc loc, int isunion, Array *decl); |
114 Dsymbol *syntaxCopy(Dsymbol *s); | 118 Dsymbol *syntaxCopy(Dsymbol *s); |
115 void semantic(Scope *sc); | 119 void semantic(Scope *sc); |