Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/Parser/DeclarationNode.cc

    rde62360d r721f17a  
    1010// Created On       : Sat May 16 12:34:05 2015
    1111// Last Modified By : Peter A. Buhr
    12 // Last Modified On : Wed Jun 24 15:29:19 2015
    13 // Update Count     : 86
     12// Last Modified On : Fri Jun 26 23:36:03 2015
     13// Update Count     : 105
    1414//
    1515
     
    173173}
    174174
    175 DeclarationNode *DeclarationNode::newAggregate( Aggregate kind, std::string *name, DeclarationNode *formals, ExpressionNode *actuals, DeclarationNode *fields ) {
     175DeclarationNode *DeclarationNode::newAggregate( Aggregate kind, std::string *name, ExpressionNode *actuals, DeclarationNode *fields ) {
    176176        DeclarationNode *newnode = new DeclarationNode;
    177177        newnode->type = new TypeData( TypeData::Aggregate );
     
    189189        newnode->appendList( typedf->addType( newnode->clone() )->addTypedef() );
    190190
    191         newnode->type->aggregate->params = formals;
    192191        newnode->type->aggregate->actuals = actuals;
    193         newnode->type->aggregate->members = fields;
     192        newnode->type->aggregate->fields = fields;
    194193        return newnode;
    195194}
     
    251250        newnode->type->aggregate->kind = Context;
    252251        newnode->type->aggregate->params = params;
    253         newnode->type->aggregate->members = asserts;
     252        newnode->type->aggregate->fields = asserts;
    254253        newnode->type->aggregate->name = assign_strptr( name );
    255254        return newnode;
     
    371370                                        if ( type->kind == TypeData::Aggregate ) {
    372371                                                type->aggregate->params = q->type->forall;
     372                                                // change implicit typedef from TYPEDEFname to TYPEGENname
     373                                                typedefTable.changeKind( type->aggregate->name, TypedefTable::TG );
    373374                                        } else {
    374375                                                type->forall = q->type->forall;
     
    407408                                src = 0;
    408409                                break;
    409 
    410410                          case TypeData::Basic:
    411411                                dst->qualifiers.splice( dst->qualifiers.end(), src->qualifiers );
     
    416416                                } // if
    417417                                break;
    418 
    419418                          default:
    420419                                switch ( src->kind ) {
     
    429428                                        src = 0;
    430429                                        break;
    431 
    432430                                  default:
    433431                                        if ( dst->forall ) {
     
    684682                } else {
    685683                        assert( newnode->type->aggInst->aggregate->kind == TypeData::Aggregate );
    686                         delete newnode->type->aggInst->aggregate->aggregate->members;
    687                         newnode->type->aggInst->aggregate->aggregate->members = 0;
     684                        delete newnode->type->aggInst->aggregate->aggregate->fields;
     685                        newnode->type->aggInst->aggregate->aggregate->fields = 0;
    688686                } // if
    689687        } // if
     
    710708                                } else {
    711709                                        assert( newType->aggInst->aggregate->kind == TypeData::Aggregate );
    712                                         delete newType->aggInst->aggregate->aggregate->members;
    713                                         newType->aggInst->aggregate->aggregate->members = 0;
     710                                        delete newType->aggInst->aggregate->aggregate->fields;
     711                                        newType->aggInst->aggregate->aggregate->fields = 0;
    714712                                } // if
    715713                        } // if
Note: See TracChangeset for help on using the changeset viewer.