Changeset 567bb17 for src/GenPoly


Ignore:
Timestamp:
Jan 21, 2016, 4:51:51 PM (9 years ago)
Author:
Aaron Moss <a3moss@…>
Branches:
ADT, aaron-thesis, arm-eh, ast-experimental, cleanup-dtors, ctor, deferred_resn, demangler, enum, forall-pointer-decay, gc_noraii, jacob/cs343-translation, jenkins-sandbox, master, memory, new-ast, new-ast-unique-expr, new-env, no_list, persistent-indexer, pthread-emulation, qualifiedEnum, resolv-new, string, with_gc
Children:
4ef7506
Parents:
421edab
Message:

fix (?) void* errors on member offsets

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/GenPoly/Box.cc

    r421edab r567bb17  
    13171317                        if ( decl == baseDecls.end() ) return memberExpr;
    13181318
    1319                         // replace member expression with dereference of pointer offset
     1319                        // replace member expression with pointer to base plus offset
     1320                        // this is in a polymorphic context, so maybe keeping it as a void* is fine?
    13201321                        std::stringstream offset_namer;
    13211322                        offset_namer << i;
     
    13271328                        fieldLoc->get_args().push_back( memberExpr->get_aggregate() );
    13281329                        fieldLoc->get_args().push_back( fieldOffset );
    1329                         UntypedExpr *ret = new UntypedExpr( new NameExpr( "*?" ) );
    1330                         ret->get_args().push_back( fieldLoc );
    13311330
    13321331                        memberExpr->set_aggregate( 0 );
    13331332                        delete memberExpr;
    1334                         return ret;
     1333                        return fieldLoc;
    13351334                }
    13361335
Note: See TracChangeset for help on using the changeset viewer.