Changeset 0b3b2ae for src/CodeGen


Ignore:
Timestamp:
Jun 22, 2018, 3:43:19 PM (6 years ago)
Author:
Rob Schluntz <rschlunt@…>
Branches:
ADT, aaron-thesis, arm-eh, ast-experimental, cleanup-dtors, deferred_resn, demangler, enum, forall-pointer-decay, jacob/cs343-translation, jenkins-sandbox, master, new-ast, new-ast-unique-expr, no_list, persistent-indexer, pthread-emulation, qualifiedEnum
Children:
ed34540
Parents:
c194661
git-author:
Rob Schluntz <rschlunt@…> (06/22/18 14:48:30)
git-committer:
Rob Schluntz <rschlunt@…> (06/22/18 15:43:19)
Message:

Minor code cleanup

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/CodeGen/CodeGenerator.cc

    rc194661 r0b3b2ae  
    164164                previsit( (BaseSyntaxNode *)node );
    165165                GuardAction( [this, node](){
    166                         if ( printExprTypes ) {
     166                        if ( printExprTypes && node->result ) {
    167167                                output << " /* " << genType( node->result, "", pretty, genC ) << " */ ";
    168168                        }
     
    224224
    225225        void CodeGenerator::handleAggregate( AggregateDecl * aggDecl, const std::string & kind ) {
    226                 if( ! aggDecl->get_parameters().empty() && ! genC ) {
     226                if( ! aggDecl->parameters.empty() && ! genC ) {
    227227                        // assertf( ! genC, "Aggregate type parameters should not reach code generation." );
    228228                        output << "forall(";
    229                         genCommaList( aggDecl->get_parameters().begin(), aggDecl->get_parameters().end() );
     229                        genCommaList( aggDecl->parameters.begin(), aggDecl->parameters.end() );
    230230                        output << ")" << endl;
    231231                        output << indent;
     
    233233
    234234                output << kind;
    235                 genAttributes( aggDecl->get_attributes() );
    236                 output << aggDecl->get_name();
     235                genAttributes( aggDecl->attributes );
     236                output << aggDecl->name;
    237237
    238238                if ( aggDecl->has_body() ) {
    239                         std::list< Declaration * > & memb = aggDecl->get_members();
     239                        std::list< Declaration * > & memb = aggDecl->members;
    240240                        output << " {" << endl;
    241241
Note: See TracChangeset for help on using the changeset viewer.