Changeset 549c006 for src/InitTweak


Ignore:
Timestamp:
Sep 29, 2017, 12:18:51 PM (6 years ago)
Author:
Thierry Delisle <tdelisle@…>
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, new-env, no_list, persistent-indexer, pthread-emulation, qualifiedEnum, resolv-new, with_gc
Children:
b8116cd
Parents:
ea156ae
Message:

Implemented out of order waitfor for destructors

Location:
src/InitTweak
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • src/InitTweak/InitTweak.cc

    rea156ae r549c006  
    270270        }
    271271
    272         Type * getThisType( FunctionType * ftype ) {
    273                 assertf( ftype, "getThisType: nullptr ftype" );
    274                 ObjectDecl * thisParam = getThisParam( ftype );
     272        Type * getTypeofThis( FunctionType * ftype ) {
     273                assertf( ftype, "getTypeofThis: nullptr ftype" );
     274                ObjectDecl * thisParam = getParamThis( ftype );
    275275                ReferenceType * refType = strict_dynamic_cast< ReferenceType * >( thisParam->type );
    276276                return refType->base;
    277277        }
    278278
    279         ObjectDecl * getThisParam( FunctionType * ftype ) {
    280                 assertf( ftype, "getThisParam: nullptr ftype" );
     279        ObjectDecl * getParamThis( FunctionType * ftype ) {
     280                assertf( ftype, "getParamThis: nullptr ftype" );
    281281                auto & params = ftype->parameters;
    282                 assertf( ! params.empty(), "getThisParam: ftype with 0 parameters: %s", toString( ftype ).c_str() );
     282                assertf( ! params.empty(), "getParamThis: ftype with 0 parameters: %s", toString( ftype ).c_str() );
    283283                return strict_dynamic_cast< ObjectDecl * >( params.front() );
    284284        }
  • src/InitTweak/InitTweak.h

    rea156ae r549c006  
    3131
    3232        /// returns the base type of the first parameter to a constructor/destructor/assignment function
    33         Type * getThisType( FunctionType * ftype );
     33        Type * getTypeofThis( FunctionType * ftype );
    3434
    3535        /// returns the first parameter of a constructor/destructor/assignment function
    36         ObjectDecl * getThisParam( FunctionType * ftype );
     36        ObjectDecl * getParamThis( FunctionType * ftype );
    3737
    3838        /// transform Initializer into an argument list that can be passed to a call expression
Note: See TracChangeset for help on using the changeset viewer.