Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/GenPoly/Box.cc

    r974906e2 r1cced28  
    1010// Created On       : Mon May 18 07:44:20 2015
    1111// Last Modified By : Rob Schluntz
    12 // Last Modified On : Thu Jan 07 13:40:05 2016
    13 // Update Count     : 219
     12// Last Modified On : Fri Dec 18 14:53:08 2015
     13// Update Count     : 217
    1414//
    1515
     
    412412                void Pass1::boxParam( Type *param, Expression *&arg, const TyVarMap &exprTyVars ) {
    413413                        assert( ! arg->get_results().empty() );
    414 //   if ( ! dynamic_cast< PointerType *>( arg->get_results().front() ) ) {
    415                         TypeInstType *typeInst = dynamic_cast< TypeInstType *>( param );
    416                         if ( typeInst && exprTyVars.find( typeInst->get_name() ) != exprTyVars.end() ) {
     414                        if ( isPolyType( param, exprTyVars ) ) {
    417415                                if ( dynamic_cast< TypeInstType *>( arg->get_results().front() ) ) {
    418416                                        // if the argument's type is a type parameter, we don't need to box again!
     
    432430                                } // if
    433431                        } // if
    434 //   }
    435432                }
    436433
     
    11421139
    11431140                                        std::list<Expression*> designators;
    1144                                         objectDecl->set_init( new SingleInit( alloc, designators, false ) ); // not constructed
     1141                                        objectDecl->set_init( new SingleInit( alloc, designators ) );
    11451142                                }
    11461143                        }
Note: See TracChangeset for help on using the changeset viewer.