Mercurial > projects > ldc
view dmd/attrib.h @ 1607:207a8a438dea
Merge DMD r253: refactor: Argument => Parameter
---
dmd/arrayop.c | 30 ++++----
dmd/arraytypes.h | 2 +-
dmd/class.c | 8 +-
dmd/declaration.c | 10 ++--
dmd/declaration.h | 16 ++--
dmd/doc.c | 12 ++--
dmd/dsymbol.c | 4 +-
dmd/expression.c | 48 +++++++-------
dmd/expression.h | 32 +++++-----
dmd/func.c | 78 +++++++++++-----------
dmd/init.c | 2 +-
dmd/interpret.c | 8 +-
dmd/mtype.c | 190 ++++++++++++++++++++++++++--------------------------
dmd/mtype.h | 32 +++++-----
dmd/opover.c | 34 +++++-----
dmd/parse.c | 40 ++++++------
dmd/parse.h | 2 +-
dmd/statement.c | 90 +++++++++++++-------------
dmd/statement.h | 14 ++--
dmd/struct.c | 8 +-
dmd/template.c | 30 ++++----
gen/functions.cpp | 10 ++--
gen/functions.h | 2 +-
gen/tocall.cpp | 10 ++--
gen/typinf.cpp | 6 +-
25 files changed, 359 insertions(+), 359 deletions(-)
author | Leandro Lucarella <llucax@gmail.com> |
---|---|
date | Wed, 06 Jan 2010 15:18:20 -0300 |
parents | a413ae7329bf |
children |
line wrap: on
line source
// Compiler implementation of the D programming language // Copyright (c) 1999-2009 by Digital Mars // All Rights Reserved // written by Walter Bright // http://www.digitalmars.com // License for redistribution is by either the Artistic License // in artistic.txt, or the GNU General Public License in gnu.txt. // See the included readme.txt for details. #ifndef DMD_ATTRIB_H #define DMD_ATTRIB_H #ifdef __DMC__ #pragma once #endif /* __DMC__ */ #include "dsymbol.h" struct Expression; struct Statement; struct LabelDsymbol; struct Initializer; struct Module; struct Condition; #ifdef _DH struct HdrGenState; #endif /**************************************************************/ struct AttribDeclaration : Dsymbol { Array *decl; // array of Dsymbol's AttribDeclaration(Array *decl); virtual Array *include(Scope *sc, ScopeDsymbol *s); int addMember(Scope *sc, ScopeDsymbol *s, int memnum); void setScopeNewSc(Scope *sc, StorageClass newstc, enum LINK linkage, enum PROT protection, int explictProtection, unsigned structalign); void semanticNewSc(Scope *sc, StorageClass newstc, enum LINK linkage, enum PROT protection, int explictProtection, unsigned structalign); void semantic(Scope *sc); void semantic2(Scope *sc); void semantic3(Scope *sc); void inlineScan(); void addComment(unsigned char *comment); void emitComment(Scope *sc); const char *kind(); int oneMember(Dsymbol **ps); int hasPointers(); void checkCtorConstInit(); void addLocalClass(ClassDeclarations *); void toCBuffer(OutBuffer *buf, HdrGenState *hgs); void toJsonBuffer(OutBuffer *buf); AttribDeclaration *isAttribDeclaration() { return this; } #if IN_DMD virtual void toObjFile(int multiobj); // compile to .obj file int cvMember(unsigned char *p); #endif #if IN_LLVM virtual void codegen(Ir*); #endif }; struct StorageClassDeclaration: AttribDeclaration { StorageClass stc; StorageClassDeclaration(StorageClass stc, Array *decl); Dsymbol *syntaxCopy(Dsymbol *s); void setScope(Scope *sc); void semantic(Scope *sc); void toCBuffer(OutBuffer *buf, HdrGenState *hgs); static void stcToCBuffer(OutBuffer *buf, StorageClass stc); }; struct LinkDeclaration : AttribDeclaration { enum LINK linkage; LinkDeclaration(enum LINK p, Array *decl); Dsymbol *syntaxCopy(Dsymbol *s); void setScope(Scope *sc); void semantic(Scope *sc); void semantic3(Scope *sc); void toCBuffer(OutBuffer *buf, HdrGenState *hgs); char *toChars(); }; struct ProtDeclaration : AttribDeclaration { enum PROT protection; ProtDeclaration(enum PROT p, Array *decl); Dsymbol *syntaxCopy(Dsymbol *s); void importAll(Scope *sc); void setScope(Scope *sc); void semantic(Scope *sc); void toCBuffer(OutBuffer *buf, HdrGenState *hgs); static void protectionToCBuffer(OutBuffer *buf, enum PROT protection); }; struct AlignDeclaration : AttribDeclaration { unsigned salign; AlignDeclaration(Loc loc, unsigned sa, Array *decl); Dsymbol *syntaxCopy(Dsymbol *s); void setScope(Scope *sc); void semantic(Scope *sc); void toCBuffer(OutBuffer *buf, HdrGenState *hgs); }; struct AnonDeclaration : AttribDeclaration { int isunion; int sem; // 1 if successful semantic() AnonDeclaration(Loc loc, int isunion, Array *decl); Dsymbol *syntaxCopy(Dsymbol *s); void semantic(Scope *sc); void toCBuffer(OutBuffer *buf, HdrGenState *hgs); const char *kind(); }; struct PragmaDeclaration : AttribDeclaration { Expressions *args; // array of Expression's PragmaDeclaration(Loc loc, Identifier *ident, Expressions *args, Array *decl); Dsymbol *syntaxCopy(Dsymbol *s); void semantic(Scope *sc); void setScope(Scope *sc); int oneMember(Dsymbol **ps); void toCBuffer(OutBuffer *buf, HdrGenState *hgs); const char *kind(); #if IN_DMD void toObjFile(int multiobj); // compile to .obj file #endif #if IN_LLVM void codegen(Ir*); #endif }; struct ConditionalDeclaration : AttribDeclaration { Condition *condition; Array *elsedecl; // array of Dsymbol's for else block ConditionalDeclaration(Condition *condition, Array *decl, Array *elsedecl); Dsymbol *syntaxCopy(Dsymbol *s); int oneMember(Dsymbol **ps); void emitComment(Scope *sc); Array *include(Scope *sc, ScopeDsymbol *s); void addComment(unsigned char *comment); void toCBuffer(OutBuffer *buf, HdrGenState *hgs); void toJsonBuffer(OutBuffer *buf); void importAll(Scope *sc); void setScope(Scope *sc); }; struct StaticIfDeclaration : ConditionalDeclaration { ScopeDsymbol *sd; int addisdone; StaticIfDeclaration(Condition *condition, Array *decl, Array *elsedecl); Dsymbol *syntaxCopy(Dsymbol *s); int addMember(Scope *sc, ScopeDsymbol *s, int memnum); void semantic(Scope *sc); void importAll(Scope *sc); void setScope(Scope *sc); const char *kind(); }; // Mixin declarations struct CompileDeclaration : AttribDeclaration { Expression *exp; ScopeDsymbol *sd; int compiled; CompileDeclaration(Loc loc, Expression *exp); Dsymbol *syntaxCopy(Dsymbol *s); int addMember(Scope *sc, ScopeDsymbol *sd, int memnum); void compileIt(Scope *sc); void semantic(Scope *sc); void toCBuffer(OutBuffer *buf, HdrGenState *hgs); }; #endif /* DMD_ATTRIB_H */