Changeset f74eb47 for src/GenPoly
- Timestamp:
- Apr 17, 2018, 4:31:07 PM (7 years ago)
- 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, with_gc
- Children:
- b2da0574
- Parents:
- 70a5acf
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/GenPoly/Lvalue.cc
r70a5acf rf74eb47 276 276 277 277 Expression * AddrRef::postmutate( AddressExpr * addrExpr ) { 278 PRINT( std::cerr << "addr ref at " << addrExpr << std::endl; ) 278 279 if ( refDepth == 0 ) { 280 PRINT( std::cerr << "depth 0, get new depth..." << std::endl; ) 279 281 // this is the innermost address-of in a chain, record depth D 280 282 if ( ! isIntrinsicReference( addrExpr->arg ) ) { … … 282 284 // xxx - is this condition still necessary? intrinsicReferences should have a cast around them at this point, so I don't think this condition ever fires. 283 285 refDepth = addrExpr->arg->result->referenceDepth(); 286 PRINT( std::cerr << "arg not intrinsic reference, new depth is: " << refDepth << std::endl; ) 284 287 } else { 285 288 assertf( false, "AddrRef : address-of should not have intrinsic reference argument: %s", toCString( addrExpr->arg ) ); … … 287 290 } 288 291 if ( current ) { // this is the outermost address-of in a chain 292 PRINT( std::cerr << "current, depth is: " << refDepth << std::endl; ) 289 293 Expression * ret = addrExpr; 290 294 while ( refDepth ) { … … 295 299 296 300 if ( addCast ) { 301 PRINT( std::cerr << "adding cast..." << std::endl; ) 297 302 return new CastExpr( ret, addrExpr->result->clone() ); 298 303 } 299 304 return ret; 300 305 } 306 PRINT( std::cerr << "not current..." << std::endl; ) 301 307 return addrExpr; 302 308 }
Note: See TracChangeset
for help on using the changeset viewer.