Changeset 7156c46 for src/ControlStruct/ExceptDeclNew.cpp
- Timestamp:
- Aug 11, 2023, 11:24:34 AM (12 months ago)
- Branches:
- master
- Children:
- 409bb8f, 89bef959, c1f502c
- Parents:
- b2ab352
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/ControlStruct/ExceptDeclNew.cpp
rb2ab352 r7156c46 242 242 } 243 243 244 ast::ObjectDecl const* createExternVTable(244 static ast::ObjectDecl * createExternVTable( 245 245 CodeLocation const & location, 246 246 std::string const & exceptionName, … … 356 356 } 357 357 358 ast::ObjectDecl const* createVirtualTable(358 ast::ObjectDecl * createVirtualTable( 359 359 CodeLocation const & location, 360 360 std::string const & exceptionName, … … 451 451 std::string const & tableName = decl->name; 452 452 453 ast::ObjectDecl * retDecl; 453 454 if ( decl->storage.is_extern ) { 454 455 // Unique type-ids are only needed for polymorphic instances. … … 457 458 createExternTypeId( location, exceptionName, params ) ); 458 459 } 459 ret urncreateExternVTable( location, exceptionName, params, tableName );460 retDecl = createExternVTable( location, exceptionName, params, tableName ); 460 461 } else { 461 462 // Unique type-ids are only needed for polymorphic instances. … … 468 469 declsToAddBefore.push_back( 469 470 createMsg( location, exceptionName, params ) ); 470 ret urncreateVirtualTable(471 retDecl = createVirtualTable( 471 472 location, exceptionName, params, tableName ); 472 473 } 474 475 for ( ast::ptr<ast::Attribute> const & attr : decl->attributes ) { 476 retDecl->attributes.push_back( attr ); 477 } 478 479 return retDecl; 473 480 } 474 481 … … 476 483 ast::StructInstType const * postvisit( ast::VTableType const * type ) { 477 484 auto inst = type->base.as<ast::BaseInstType>(); 478 485 479 486 std::string vtableName = Virtual::vtableTypeName( inst->name ); 487 480 488 auto newType = new ast::StructInstType( vtableName ); 481 489 for ( ast::ptr<ast::Expr> const & param : inst->params ) {
Note: See TracChangeset
for help on using the changeset viewer.