Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/Parser/ParseNode.h

    rf271bdd rf2f512ba  
    1010// Created On       : Sat May 16 13:28:16 2015
    1111// Last Modified By : Peter A. Buhr
    12 // Last Modified On : Sat Aug  4 09:39:40 2018
    13 // Update Count     : 853
     12// Last Modified On : Fri Jul 20 14:56:30 2018
     13// Update Count     : 850
    1414//
    1515
     
    132132        void printOneLine( __attribute__((unused)) std::ostream & os, __attribute__((unused)) int indent = 0 ) const {}
    133133
    134         Expression *get_expr() const { return expr.get(); }
    135134        template<typename T>
    136135        bool isExpressionType() const { return nullptr != dynamic_cast<T>(expr.get()); }
     
    391390Statement * build_expr( ExpressionNode * ctl );
    392391
    393 struct IfCtrl {
    394         IfCtrl( DeclarationNode * decl, ExpressionNode * condition ) :
     392struct IfCtl {
     393        IfCtl( DeclarationNode * decl, ExpressionNode * condition ) :
    395394                init( decl ? new StatementNode( decl ) : nullptr ), condition( condition ) {}
    396395
     
    399398};
    400399
    401 struct ForCtrl {
    402         ForCtrl( ExpressionNode * expr, ExpressionNode * condition, ExpressionNode * change ) :
     400struct ForCtl {
     401        ForCtl( ExpressionNode * expr, ExpressionNode * condition, ExpressionNode * change ) :
    403402                init( new StatementNode( build_expr( expr ) ) ), condition( condition ), change( change ) {}
    404         ForCtrl( DeclarationNode * decl, ExpressionNode * condition, ExpressionNode * change ) :
     403        ForCtl( DeclarationNode * decl, ExpressionNode * condition, ExpressionNode * change ) :
    405404                init( new StatementNode( decl ) ), condition( condition ), change( change ) {}
    406405
     
    410409};
    411410
    412 Expression * build_if_control( IfCtrl * ctl, std::list< Statement * > & init );
    413 Statement * build_if( IfCtrl * ctl, StatementNode * then_stmt, StatementNode * else_stmt );
     411Expression * build_if_control( IfCtl * ctl, std::list< Statement * > & init );
     412Statement * build_if( IfCtl * ctl, StatementNode * then_stmt, StatementNode * else_stmt );
    414413Statement * build_switch( bool isSwitch, ExpressionNode * ctl, StatementNode * stmt );
    415414Statement * build_case( ExpressionNode * ctl );
    416415Statement * build_default();
    417 Statement * build_while( IfCtrl * ctl, StatementNode * stmt );
     416Statement * build_while( IfCtl * ctl, StatementNode * stmt );
    418417Statement * build_do_while( ExpressionNode * ctl, StatementNode * stmt );
    419 Statement * build_for( ForCtrl * forctl, StatementNode * stmt );
     418Statement * build_for( ForCtl * forctl, StatementNode * stmt );
    420419Statement * build_branch( BranchStmt::Type kind );
    421420Statement * build_branch( std::string * identifier, BranchStmt::Type kind );
Note: See TracChangeset for help on using the changeset viewer.