Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/CodeGen/CodeGenerator.cc

    r486341f r906e24d  
    309309                                                        UntypedExpr * newExpr = new UntypedExpr( new NameExpr( "*?" ) );
    310310                                                        newExpr->get_args().push_back( *arg );
    311                                                         assert( (*arg)->get_results().size() == 1 );
    312                                                         Type * type = InitTweak::getPointerBase( (*arg)->get_results().front() );
     311                                                        Type * type = InitTweak::getPointerBase( (*arg)->get_result() );
    313312                                                        assert( type );
    314                                                         newExpr->get_results().push_back( type->clone() );
     313                                                        newExpr->set_result( type->clone() );
    315314                                                        *arg = newExpr;
    316315                                                } // if
     
    527526                extension( castExpr );
    528527                output << "(";
    529                 if ( castExpr->get_results().empty() ) {
     528                if ( castExpr->get_result()->isVoid() ) {
    530529                        output << "(void)" ;
    531                 } else if ( ! castExpr->get_results().front()->get_isLvalue() ) {
     530                } else if ( ! castExpr->get_result()->get_isLvalue() ) {
    532531                        // at least one result type of cast, but not an lvalue
    533532                        output << "(";
    534                         output << genType( castExpr->get_results().front(), "" );
     533                        output << genType( castExpr->get_result(), "" );
    535534                        output << ")";
    536535                } else {
Note: See TracChangeset for help on using the changeset viewer.