Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/AST/Print.cpp

    re67991f ra7d50b6  
    3737}
    3838
    39 class Printer final : public Visitor {
     39class Printer : public Visitor {
    4040public:
    4141        ostream & os;
     
    272272
    273273public:
    274         virtual const ast::DeclWithType * visit( const ast::ObjectDecl * node ) override final {
     274        virtual const ast::DeclWithType * visit( const ast::ObjectDecl * node ) {
    275275                if ( ! node->name.empty() ) os << node->name << ": ";
    276276
     
    314314        }
    315315
    316         virtual const ast::DeclWithType * visit( const ast::FunctionDecl * node ) override final {
     316        virtual const ast::DeclWithType * visit( const ast::FunctionDecl * node ) {
    317317                if ( !node->name.empty() ) os << node->name << ": ";
    318318
     
    342342        }
    343343
    344         virtual const ast::Decl * visit( const ast::StructDecl * node ) override final {
     344        virtual const ast::Decl * visit( const ast::StructDecl * node ) {
    345345                print(node);
    346346                return node;
    347347        }
    348348
    349         virtual const ast::Decl * visit( const ast::UnionDecl * node ) override final {
     349        virtual const ast::Decl * visit( const ast::UnionDecl * node ) {
    350350                print(node);
    351351                return node;
    352352        }
    353353
    354         virtual const ast::Decl * visit( const ast::EnumDecl * node ) override final {
     354        virtual const ast::Decl * visit( const ast::EnumDecl * node ) {
    355355                print(node);
    356356                return node;
    357357        }
    358358
    359         virtual const ast::Decl * visit( const ast::TraitDecl * node ) override final {
     359        virtual const ast::Decl * visit( const ast::TraitDecl * node ) {
    360360                print(node);
    361361                return node;
    362362        }
    363363
    364         virtual const ast::Decl * visit( const ast::TypeDecl * node ) override final {
     364        virtual const ast::Decl * visit( const ast::TypeDecl * node ) {
    365365                preprint( node );
    366366                if ( ! short_mode && node->init ) {
     
    374374        }
    375375
    376         virtual const ast::Decl * visit( const ast::TypedefDecl * node ) override final {
    377                 preprint( node );
    378                 return node;
    379         }
    380 
    381         virtual const ast::AsmDecl * visit( const ast::AsmDecl * node ) override final {
     376        virtual const ast::Decl * visit( const ast::TypedefDecl * node ) {
     377                preprint( node );
     378                return node;
     379        }
     380
     381        virtual const ast::AsmDecl * visit( const ast::AsmDecl * node ) {
    382382                safe_print( node->stmt );
    383383                return node;
    384384        }
    385385
    386         virtual const ast::StaticAssertDecl * visit( const ast::StaticAssertDecl * node ) override final {
     386        virtual const ast::StaticAssertDecl * visit( const ast::StaticAssertDecl * node ) {
    387387                os << "Static Assert with condition: ";
    388388                ++indent;
     
    396396        }
    397397
    398         virtual const ast::CompoundStmt * visit( const ast::CompoundStmt * node ) override final {
     398        virtual const ast::CompoundStmt * visit( const ast::CompoundStmt * node ) {
    399399                os << "Compound Statement:" << endl;
    400400                ++indent;
     
    404404        }
    405405
    406         virtual const ast::Stmt * visit( const ast::ExprStmt * node ) override final {
     406        virtual const ast::Stmt * visit( const ast::ExprStmt * node ) {
    407407                ++indent;
    408408                os << "Expression Statement:" << endl << indent;
     
    412412        }
    413413
    414         virtual const ast::Stmt * visit( const ast::AsmStmt * node ) override final {
     414        virtual const ast::Stmt * visit( const ast::AsmStmt * node ) {
    415415                os << "Assembler Statement:" << endl;
    416416                ++indent;
     
    433433        }
    434434
    435         virtual const ast::Stmt * visit( const ast::DirectiveStmt * node ) override final {
     435        virtual const ast::Stmt * visit( const ast::DirectiveStmt * node ) {
    436436                os << "GCC Directive: " << node->directive << endl;
    437437                return node;
    438438        }
    439439
    440         virtual const ast::Stmt * visit( const ast::IfStmt * node ) override final {
     440        virtual const ast::Stmt * visit( const ast::IfStmt * node ) {
    441441                os << "If on condition:" << endl;
    442442                ++indent;
     
    473473        }
    474474
    475         virtual const ast::Stmt * visit( const ast::WhileStmt * node ) override final {
     475        virtual const ast::Stmt * visit( const ast::WhileStmt * node ) {
    476476                if ( node->isDoWhile ) { os << "Do-"; }
    477477                os << "While on condition:" << endl;
     
    490490        }
    491491
    492         virtual const ast::Stmt * visit( const ast::ForStmt * node ) override final {
     492        virtual const ast::Stmt * visit( const ast::ForStmt * node ) {
    493493                os << "For Statement" << endl;
    494494
     
    532532        }
    533533
    534         virtual const ast::Stmt * visit( const ast::SwitchStmt * node ) override final {
     534        virtual const ast::Stmt * visit( const ast::SwitchStmt * node ) {
    535535                os << "Switch on condition: ";
    536536                safe_print( node->cond );
     
    546546        }
    547547
    548         virtual const ast::Stmt * visit( const ast::CaseStmt * node ) override final {
     548        virtual const ast::Stmt * visit( const ast::CaseStmt * node ) {
    549549                if ( node->isDefault() ) {
    550550                        os << indent << "Default ";
     
    565565        }
    566566
    567         virtual const ast::Stmt * visit( const ast::BranchStmt * node ) override final {
     567        virtual const ast::Stmt * visit( const ast::BranchStmt * node ) {
    568568                os << "Branch (" << node->kindName() << ")" << endl;
    569569                ++indent;
     
    586586        }
    587587
    588         virtual const ast::Stmt * visit( const ast::ReturnStmt * node ) override final {
     588        virtual const ast::Stmt * visit( const ast::ReturnStmt * node ) {
    589589                os << "Return Statement, returning";
    590590                if ( node->expr ) {
     
    601601        }
    602602
    603         virtual const ast::Stmt * visit( const ast::ThrowStmt * node ) override final {
     603        virtual const ast::Stmt * visit( const ast::ThrowStmt * node ) {
    604604                if ( node->target ) os << "Non-Local ";
    605605
     
    621621        }
    622622
    623         virtual const ast::Stmt * visit( const ast::TryStmt * node ) override final {
     623        virtual const ast::Stmt * visit( const ast::TryStmt * node ) {
    624624                ++indent;
    625625                os << "Try Statement" << endl << indent-1
     
    642642        }
    643643
    644         virtual const ast::Stmt * visit( const ast::CatchStmt * node ) override final {
     644        virtual const ast::Stmt * visit( const ast::CatchStmt * node ) {
    645645                os << "Catch ";
    646646                switch ( node->kind ) {
     
    667667        }
    668668
    669         virtual const ast::Stmt * visit( const ast::FinallyStmt * node ) override final {
     669        virtual const ast::Stmt * visit( const ast::FinallyStmt * node ) {
    670670                os << "Finally Statement" << endl;
    671671                os << indent << "... with block:" << endl;
     
    678678        }
    679679
    680         virtual const ast::Stmt * visit( const ast::WaitForStmt * node ) override final {
     680        virtual const ast::Stmt * visit( const ast::WaitForStmt * node ) {
    681681                os << "Waitfor Statement" << endl;
    682682                indent += 2;
     
    732732        }
    733733
    734         virtual const ast::Decl * visit( const ast::WithStmt * node ) override final {
     734        virtual const ast::Stmt * visit( const ast::WithStmt * node ) {
    735735                os << "With statement" << endl;
    736736                os << indent << "... with expressions:" << endl;
     
    744744        }
    745745
    746         virtual const ast::NullStmt * visit( const ast::NullStmt * node ) override final {
     746        virtual const ast::NullStmt * visit( const ast::NullStmt * node ) {
    747747                os << "Null Statement" << endl;
    748748                print( node->labels );
     
    751751        }
    752752
    753         virtual const ast::Stmt * visit( const ast::DeclStmt * node ) override final {
     753        virtual const ast::Stmt * visit( const ast::DeclStmt * node ) {
    754754                os << "Declaration of ";
    755755                safe_print( node->decl );
     
    758758        }
    759759
    760         virtual const ast::Stmt * visit( const ast::ImplicitCtorDtorStmt * node ) override final {
     760        virtual const ast::Stmt * visit( const ast::ImplicitCtorDtorStmt * node ) {
    761761                os << "Implicit Ctor Dtor Statement" << endl;
    762762                os << indent << "... with Ctor/Dtor: ";
     
    769769        }
    770770
    771         virtual const ast::Expr * visit( const ast::ApplicationExpr * node ) override final {
     771        virtual const ast::Expr * visit( const ast::ApplicationExpr * node ) {
    772772                ++indent;
    773773                os << "Application of" << endl << indent;
     
    784784        }
    785785
    786         virtual const ast::Expr * visit( const ast::UntypedExpr * node ) override final {
     786        virtual const ast::Expr * visit( const ast::UntypedExpr * node ) {
    787787                ++indent;
    788788                os << "Applying untyped:" << endl;
     
    797797        }
    798798
    799         virtual const ast::Expr * visit( const ast::NameExpr * node ) override final {
     799        virtual const ast::Expr * visit( const ast::NameExpr * node ) {
    800800                os << "Name: " << node->name;
    801801                postprint( node );
     
    804804        }
    805805
    806         virtual const ast::Expr * visit( const ast::AddressExpr * node ) override final {
     806        virtual const ast::Expr * visit( const ast::AddressExpr * node ) {
    807807                os << "Address of:" << endl;
    808808                ++indent;
     
    815815        }
    816816
    817         virtual const ast::Expr * visit( const ast::LabelAddressExpr * node ) override final {
     817        virtual const ast::Expr * visit( const ast::LabelAddressExpr * node ) {
    818818                os << "Address of label:" << node->arg;
    819819
     
    821821        }
    822822
    823         virtual const ast::Expr * visit( const ast::CastExpr * node ) override final {
     823        virtual const ast::Expr * visit( const ast::CastExpr * node ) {
    824824                ++indent;
    825825                os << (node->isGenerated ? "Generated" : "Explicit") << " cast of:" << endl << indent;
     
    841841        }
    842842
    843         virtual const ast::Expr * visit( const ast::KeywordCastExpr * node ) override final {
     843        virtual const ast::Expr * visit( const ast::KeywordCastExpr * node ) {
    844844                ++indent;
    845845                os << "Keyword Cast of:" << endl << indent;
     
    852852        }
    853853
    854         virtual const ast::Expr * visit( const ast::VirtualCastExpr * node ) override final {
     854        virtual const ast::Expr * visit( const ast::VirtualCastExpr * node ) {
    855855                ++indent;
    856856                os << "Virtual Cast of:" << endl << indent;
     
    869869        }
    870870
    871         virtual const ast::Expr * visit( const ast::UntypedMemberExpr * node ) override final {
     871        virtual const ast::Expr * visit( const ast::UntypedMemberExpr * node ) {
    872872                ++indent;
    873873                os << "Untyped Member Expression, with field: " << endl << indent;
     
    881881        }
    882882
    883         virtual const ast::Expr * visit( const ast::MemberExpr * node ) override final {
     883        virtual const ast::Expr * visit( const ast::MemberExpr * node ) {
    884884                ++indent;
    885885                os << "Member Expression, with field:" << endl << indent;
     
    893893        }
    894894
    895         virtual const ast::Expr * visit( const ast::VariableExpr * node ) override final {
     895        virtual const ast::Expr * visit( const ast::VariableExpr * node ) {
    896896                os << "Variable Expression: ";
    897897                short_print( node->var );
     
    901901        }
    902902
    903         virtual const ast::Expr * visit( const ast::ConstantExpr * node ) override final {
     903        virtual const ast::Expr * visit( const ast::ConstantExpr * node ) {
    904904                os << "Constant Expression (" << node->rep;
    905905                if ( node->result ) {
     
    913913        }
    914914
    915         virtual const ast::Expr * visit( const ast::SizeofExpr * node ) override final {
     915        virtual const ast::Expr * visit( const ast::SizeofExpr * node ) {
    916916                os << "Sizeof Expression on: ";
    917917                ++indent;
     
    924924        }
    925925
    926         virtual const ast::Expr * visit( const ast::AlignofExpr * node ) override final {
     926        virtual const ast::Expr * visit( const ast::AlignofExpr * node ) {
    927927                os << "Alignof Expression on: ";
    928928                ++indent;
     
    935935        }
    936936
    937         virtual const ast::Expr * visit( const ast::UntypedOffsetofExpr * node ) override final {
     937        virtual const ast::Expr * visit( const ast::UntypedOffsetofExpr * node ) {
    938938                os << "Untyped Offsetof Expression on member " << node->member << " of ";
    939939                ++indent;
     
    945945        }
    946946
    947         virtual const ast::Expr * visit( const ast::OffsetofExpr * node ) override final {
     947        virtual const ast::Expr * visit( const ast::OffsetofExpr * node ) {
    948948                os << "Offsetof Expression on member " << node->member->name << " of ";
    949949                ++indent;
     
    955955        }
    956956
    957         virtual const ast::Expr * visit( const ast::OffsetPackExpr * node ) override final {
     957        virtual const ast::Expr * visit( const ast::OffsetPackExpr * node ) {
    958958                os << "Offset Pack Expression on: ";
    959959                ++indent;
     
    965965        }
    966966
    967         virtual const ast::Expr * visit( const ast::LogicalExpr * node ) override final {
     967        virtual const ast::Expr * visit( const ast::LogicalExpr * node ) {
    968968                os << "Short-circuited operation (" << (node->isAnd ? "and" : "or") << ") on: ";
    969969                safe_print( node->arg1 );
     
    975975        }
    976976
    977         virtual const ast::Expr * visit( const ast::ConditionalExpr * node ) override final {
     977        virtual const ast::Expr * visit( const ast::ConditionalExpr * node ) {
    978978                ++indent;
    979979                os << "Conditional expression on:" << endl << indent;
     
    989989        }
    990990
    991         virtual const ast::Expr * visit( const ast::CommaExpr * node ) override final {
     991        virtual const ast::Expr * visit( const ast::CommaExpr * node ) {
    992992                ++indent;
    993993                os << "Comma Expression:" << endl << indent;
     
    10011001        }
    10021002
    1003         virtual const ast::Expr * visit( const ast::TypeExpr * node ) override final {
     1003        virtual const ast::Expr * visit( const ast::TypeExpr * node ) {
    10041004                safe_print( node->type );
    10051005                postprint( node );
     
    10081008        }
    10091009
    1010         virtual const ast::Expr * visit( const ast::AsmExpr * node ) override final {
     1010        virtual const ast::Expr * visit( const ast::AsmExpr * node ) {
    10111011                os << "Asm Expression:" << endl;
    10121012                ++indent;
     
    10191019        }
    10201020
    1021         virtual const ast::Expr * visit( const ast::ImplicitCopyCtorExpr * node ) override final {
     1021        virtual const ast::Expr * visit( const ast::ImplicitCopyCtorExpr * node ) {
    10221022                ++indent;
    10231023                os << "Implicit Copy Constructor Expression:" << endl << indent;
    10241024                safe_print( node->callExpr );
    1025                 --indent;
    1026                 postprint( node );
    1027 
    1028                 return node;
    1029         }
    1030 
    1031         virtual const ast::Expr * visit( const ast::ConstructorExpr * node ) override final {
     1025                os << endl << indent-1 << "... with temporaries:" << endl;
     1026                printAll( node->tempDecls );
     1027                os << endl << indent-1 << "... with return temporaries:" << endl;
     1028                printAll( node->returnDecls );
     1029                --indent;
     1030                postprint( node );
     1031
     1032                return node;
     1033        }
     1034
     1035        virtual const ast::Expr * visit( const ast::ConstructorExpr * node ) {
    10321036                os <<  "Constructor Expression:" << endl << indent+1;
    10331037                indent += 2;
     
    10391043        }
    10401044
    1041         virtual const ast::Expr * visit( const ast::CompoundLiteralExpr * node ) override final {
     1045        virtual const ast::Expr * visit( const ast::CompoundLiteralExpr * node ) {
    10421046                ++indent;
    10431047                os << "Compound Literal Expression: " << endl << indent;
     
    10511055        }
    10521056
    1053         virtual const ast::Expr * visit( const ast::RangeExpr * node ) override final {
     1057        virtual const ast::Expr * visit( const ast::RangeExpr * node ) {
    10541058                os << "Range Expression: ";
    10551059                safe_print( node->low );
     
    10611065        }
    10621066
    1063         virtual const ast::Expr * visit( const ast::UntypedTupleExpr * node ) override final {
     1067        virtual const ast::Expr * visit( const ast::UntypedTupleExpr * node ) {
    10641068                os << "Untyped Tuple:" << endl;
    10651069                ++indent;
     
    10711075        }
    10721076
    1073         virtual const ast::Expr * visit( const ast::TupleExpr * node ) override final {
     1077        virtual const ast::Expr * visit( const ast::TupleExpr * node ) {
    10741078                os << "Tuple:" << endl;
    10751079                ++indent;
     
    10811085        }
    10821086
    1083         virtual const ast::Expr * visit( const ast::TupleIndexExpr * node ) override final {
     1087        virtual const ast::Expr * visit( const ast::TupleIndexExpr * node ) {
    10841088                os << "Tuple Index Expression, with tuple:" << endl;
    10851089                ++indent;
     
    10931097        }
    10941098
    1095         virtual const ast::Expr * visit( const ast::TupleAssignExpr * node ) override final {
     1099        virtual const ast::Expr * visit( const ast::TupleAssignExpr * node ) {
    10961100                os << "Tuple Assignment Expression, with stmt expr:" << endl;
    10971101                ++indent;
     
    11041108        }
    11051109
    1106         virtual const ast::Expr * visit( const ast::StmtExpr * node ) override final {
     1110        virtual const ast::Expr * visit( const ast::StmtExpr * node ) {
    11071111                ++indent;
    11081112                os << "Statement Expression:" << endl << indent;
     
    11221126        }
    11231127
    1124         virtual const ast::Expr * visit( const ast::UniqueExpr * node ) override final {
     1128        virtual const ast::Expr * visit( const ast::UniqueExpr * node ) {
    11251129                ++indent;
    11261130                os << "Unique Expression with id: " << node->id << endl << indent;
     
    11361140        }
    11371141
    1138         virtual const ast::Expr * visit( const ast::UntypedInitExpr * node ) override final {
     1142        virtual const ast::Expr * visit( const ast::UntypedInitExpr * node ) {
    11391143                ++indent;
    11401144                os << "Untyped Init Expression" << endl << indent;
     
    11521156        }
    11531157
    1154         virtual const ast::Expr * visit( const ast::InitExpr * node ) override final {
     1158        virtual const ast::Expr * visit( const ast::InitExpr * node ) {
    11551159                ++indent;
    11561160                os << "Init Expression" << endl << indent;
     
    11631167        }
    11641168
    1165         virtual const ast::Expr * visit( const ast::DeletedExpr * node ) override final {
     1169        virtual const ast::Expr * visit( const ast::DeletedExpr * node ) {
    11661170                ++indent;
    11671171                os << "Deleted Expression" << endl << indent;
     
    11741178        }
    11751179
    1176         virtual const ast::Expr * visit( const ast::DefaultArgExpr * node ) override final {
     1180        virtual const ast::Expr * visit( const ast::DefaultArgExpr * node ) {
    11771181                ++indent;
    11781182                os << "Default Argument Expression" << endl << indent;
     
    11831187        }
    11841188
    1185         virtual const ast::Expr * visit( const ast::GenericExpr * node ) override final {
     1189        virtual const ast::Expr * visit( const ast::GenericExpr * node ) {
    11861190                ++indent;
    11871191                os << "C11 _Generic Expression" << endl << indent;
     
    12061210        }
    12071211
    1208         virtual const ast::Type * visit( const ast::VoidType * node ) override final {
     1212        virtual const ast::Type * visit( const ast::VoidType * node ) {
    12091213                preprint( node );
    12101214                os << "void";
     
    12121216        }
    12131217
    1214         virtual const ast::Type * visit( const ast::BasicType * node ) override final {
     1218        virtual const ast::Type * visit( const ast::BasicType * node ) {
    12151219                preprint( node );
    12161220                os << ast::BasicType::typeNames[ node->kind ];
     
    12181222        }
    12191223
    1220         virtual const ast::Type * visit( const ast::PointerType * node ) override final {
     1224        virtual const ast::Type * visit( const ast::PointerType * node ) {
    12211225                preprint( node );
    12221226                if ( ! node->isArray() ) {
     
    12411245        }
    12421246
    1243         virtual const ast::Type * visit( const ast::ArrayType * node ) override final {
     1247        virtual const ast::Type * visit( const ast::ArrayType * node ) {
    12441248                preprint( node );
    12451249                if ( node->isStatic ) {
     
    12651269        }
    12661270
    1267         virtual const ast::Type * visit( const ast::ReferenceType * node ) override final {
     1271        virtual const ast::Type * visit( const ast::ReferenceType * node ) {
    12681272                preprint( node );
    12691273                os << "reference to ";
     
    12731277        }
    12741278
    1275         virtual const ast::Type * visit( const ast::QualifiedType * node ) override final {
     1279        virtual const ast::Type * visit( const ast::QualifiedType * node ) {
    12761280                preprint( node );
    12771281                ++indent;
     
    12861290        }
    12871291
    1288         virtual const ast::Type * visit( const ast::FunctionType * node ) override final {
     1292        virtual const ast::Type * visit( const ast::FunctionType * node ) {
    12891293                preprint( node );
    12901294
     
    13151319        }
    13161320
    1317         virtual const ast::Type * visit( const ast::StructInstType * node ) override final {
     1321        virtual const ast::Type * visit( const ast::StructInstType * node ) {
    13181322                preprint( node );
    13191323                os << "instance of struct " << node->name;
     
    13261330        }
    13271331
    1328         virtual const ast::Type * visit( const ast::UnionInstType * node ) override final {
     1332        virtual const ast::Type * visit( const ast::UnionInstType * node ) {
    13291333                preprint( node );
    13301334                os << "instance of union " << node->name;
     
    13371341        }
    13381342
    1339         virtual const ast::Type * visit( const ast::EnumInstType * node ) override final {
     1343        virtual const ast::Type * visit( const ast::EnumInstType * node ) {
    13401344                preprint( node );
    13411345                os << "instance of enum " << node->name;
     
    13481352        }
    13491353
    1350         virtual const ast::Type * visit( const ast::TraitInstType * node ) override final {
     1354        virtual const ast::Type * visit( const ast::TraitInstType * node ) {
    13511355                preprint( node );
    13521356                os << "instance of trait " << node->name;
     
    13561360        }
    13571361
    1358         virtual const ast::Type * visit( const ast::TypeInstType * node ) override final {
     1362        virtual const ast::Type * visit( const ast::TypeInstType * node ) {
    13591363                preprint( node );
    13601364                os << "instance of type " << node->name
     
    13651369        }
    13661370
    1367         virtual const ast::Type * visit( const ast::TupleType * node ) override final {
     1371        virtual const ast::Type * visit( const ast::TupleType * node ) {
    13681372                preprint( node );
    13691373                os << "tuple of types" << endl;
     
    13751379        }
    13761380
    1377         virtual const ast::Type * visit( const ast::TypeofType * node ) override final {
     1381        virtual const ast::Type * visit( const ast::TypeofType * node ) {
    13781382                preprint( node );
    13791383                if ( node->kind == ast::TypeofType::Basetypeof ) { os << "base-"; }
     
    13841388        }
    13851389
    1386         virtual const ast::Type * visit( const ast::VarArgsType * node ) override final {
     1390        virtual const ast::Type * visit( const ast::VarArgsType * node ) {
    13871391                preprint( node );
    13881392                os << "builtin var args pack";
     
    13901394        }
    13911395
    1392         virtual const ast::Type * visit( const ast::ZeroType * node ) override final {
     1396        virtual const ast::Type * visit( const ast::ZeroType * node ) {
    13931397                preprint( node );
    13941398                os << "zero_t";
     
    13961400        }
    13971401
    1398         virtual const ast::Type * visit( const ast::OneType * node ) override final {
     1402        virtual const ast::Type * visit( const ast::OneType * node ) {
    13991403                preprint( node );
    14001404                os << "one_t";
     
    14021406        }
    14031407
    1404         virtual const ast::Type * visit( const ast::GlobalScopeType * node ) override final {
     1408        virtual const ast::Type * visit( const ast::GlobalScopeType * node ) {
    14051409                preprint( node );
    14061410                os << "Global Scope Type";
     
    14081412        }
    14091413
    1410         virtual const ast::Designation * visit( const ast::Designation * node ) override final {
     1414        virtual const ast::Designation * visit( const ast::Designation * node ) {
    14111415                if ( node->designators.empty() ) return node;
    14121416                os << "... designated by: " << endl;
     
    14211425        }
    14221426
    1423         virtual const ast::Init * visit( const ast::SingleInit * node ) override final {
     1427        virtual const ast::Init * visit( const ast::SingleInit * node ) {
    14241428                os << "Simple Initializer: ";
    14251429                safe_print( node->value );
     
    14271431        }
    14281432
    1429         virtual const ast::Init * visit( const ast::ListInit * node ) override final {
     1433        virtual const ast::Init * visit( const ast::ListInit * node ) {
    14301434                os << "Compound initializer: " << endl;
    14311435                ++indent;
     
    14451449        }
    14461450
    1447         virtual const ast::Init * visit( const ast::ConstructorInit * node ) override final {
     1451        virtual const ast::Init * visit( const ast::ConstructorInit * node ) {
    14481452                os << "Constructor initializer: " << endl;
    14491453                if ( node->ctor ) {
     
    14701474        }
    14711475
    1472         virtual const ast::Attribute * visit( const ast::Attribute * node ) override final {
     1476        virtual const ast::Attribute * visit( const ast::Attribute * node ) {
    14731477                if ( node->empty() ) return node;
    14741478                os << "Attribute with name: " << node->name;
     
    14811485        }
    14821486
    1483         virtual const ast::TypeSubstitution * visit( const ast::TypeSubstitution * node ) override final {
     1487        virtual const ast::TypeSubstitution * visit( const ast::TypeSubstitution * node ) {
    14841488                os << indent << "Types:" << endl;
    14851489                for ( const auto& i : *node ) {
Note: See TracChangeset for help on using the changeset viewer.