Changeset 2a301ff for src/ControlStruct/ExceptDeclNew.cpp
- Timestamp:
- Aug 31, 2023, 11:31:15 PM (2 years ago)
- Branches:
- master
- Children:
- 950c58e
- Parents:
- 92355883 (diff), 686912c (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)
links above to see all the changes relative to each parent. - File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/ControlStruct/ExceptDeclNew.cpp
r92355883 r2a301ff 242 242 } 243 243 244 ast::ObjectDecl const* createExternVTable(244 ast::ObjectDecl * createExternVTable( 245 245 CodeLocation const & location, 246 246 std::string const & exceptionName, … … 299 299 } ), 300 300 ast::Storage::Classes(), 301 ast::Linkage::Cforall 301 ast::Linkage::Cforall, 302 { new ast::Attribute( "cfa_linkonce" ) } 302 303 ); 303 304 } … … 352 353 } ), 353 354 ast::Storage::Classes(), 354 ast::Linkage::Cforall 355 ); 356 } 357 358 ast::ObjectDecl const * createVirtualTable( 355 ast::Linkage::Cforall, 356 { new ast::Attribute( "cfa_linkonce" ) } 357 ); 358 } 359 360 ast::ObjectDecl * createVirtualTable( 359 361 CodeLocation const & location, 360 362 std::string const & exceptionName, … … 451 453 std::string const & tableName = decl->name; 452 454 455 ast::ObjectDecl * retDecl; 453 456 if ( decl->storage.is_extern ) { 454 457 // Unique type-ids are only needed for polymorphic instances. … … 457 460 createExternTypeId( location, exceptionName, params ) ); 458 461 } 459 ret urncreateExternVTable( location, exceptionName, params, tableName );462 retDecl = createExternVTable( location, exceptionName, params, tableName ); 460 463 } else { 461 464 // Unique type-ids are only needed for polymorphic instances. … … 468 471 declsToAddBefore.push_back( 469 472 createMsg( location, exceptionName, params ) ); 470 ret urncreateVirtualTable(473 retDecl = createVirtualTable( 471 474 location, exceptionName, params, tableName ); 472 475 } 476 477 for ( ast::ptr<ast::Attribute> const & attr : decl->attributes ) { 478 retDecl->attributes.push_back( attr ); 479 } 480 481 return retDecl; 473 482 } 474 483 … … 478 487 479 488 std::string vtableName = Virtual::vtableTypeName( inst->name ); 489 480 490 auto newType = new ast::StructInstType( vtableName ); 481 491 for ( ast::ptr<ast::Expr> const & param : inst->params ) {
Note:
See TracChangeset
for help on using the changeset viewer.