Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/AST/Decl.hpp

    ra1da039 rc8bf1b5  
    125125
    126126/// Object declaration `int foo()`
    127 class FunctionDecl final : public DeclWithType {
     127class FunctionDecl : public DeclWithType {
    128128public:
    129129        std::vector<ptr<TypeDecl>> type_params;
     
    314314class EnumDecl final : public AggregateDecl {
    315315public:
    316         // isTyped indicated if the enum has a declaration like:
     316        bool isTyped; // isTyped indicated if the enum has a declaration like:
    317317        // enum (type_optional) Name {...}
    318         bool isTyped;
    319         // if isTyped == true && base.get() == nullptr, it is a "void" type enum
    320         ptr<Type> base;
     318        ptr<Type> base; // if isTyped == true && base.get() == nullptr, it is a "void" type enum
    321319        enum class EnumHiding { Visible, Hide } hide;
    322320
     
    376374
    377375/// Assembly declaration: `asm ... ( "..." : ... )`
    378 class AsmDecl final : public Decl {
     376class AsmDecl : public Decl {
    379377public:
    380378        ptr<AsmStmt> stmt;
    381379
    382380        AsmDecl( const CodeLocation & loc, AsmStmt * stmt )
    383         : Decl( loc, "", {}, Linkage::C ), stmt(stmt) {}
     381        : Decl( loc, "", {}, {} ), stmt(stmt) {}
    384382
    385383        const AsmDecl * accept( Visitor & v ) const override { return v.visit( this ); }
     
    390388
    391389/// C-preprocessor directive `#...`
    392 class DirectiveDecl final : public Decl {
     390class DirectiveDecl : public Decl {
    393391public:
    394392        ptr<DirectiveStmt> stmt;
    395393
    396394        DirectiveDecl( const CodeLocation & loc, DirectiveStmt * stmt )
    397         : Decl( loc, "", {}, Linkage::C ), stmt(stmt) {}
     395        : Decl( loc, "", {}, {} ), stmt(stmt) {}
    398396
    399397        const DirectiveDecl * accept( Visitor & v ) const override { return v.visit( this ); }
     
    404402
    405403/// Static Assertion `_Static_assert( ... , ... );`
    406 class StaticAssertDecl final : public Decl {
     404class StaticAssertDecl : public Decl {
    407405public:
    408406        ptr<Expr> cond;
     
    410408
    411409        StaticAssertDecl( const CodeLocation & loc, const Expr * condition, const ConstantExpr * msg )
    412         : Decl( loc, "", {}, Linkage::C ), cond( condition ), msg( msg ) {}
     410        : Decl( loc, "", {}, {} ), cond( condition ), msg( msg ) {}
    413411
    414412        const StaticAssertDecl * accept( Visitor & v ) const override { return v.visit( this ); }
Note: See TracChangeset for help on using the changeset viewer.