Changeset 0bd3faf for src/Validate
- Timestamp:
- Nov 13, 2023, 1:40:12 PM (9 months ago)
- Branches:
- master
- Children:
- 6ea85b22
- Parents:
- 25f2798
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/Validate/Autogen.cpp
r25f2798 r0bd3faf 49 49 50 50 // -------------------------------------------------------------------------- 51 struct AutogenerateRoutines _newfinal :51 struct AutogenerateRoutines final : 52 52 public ast::WithDeclsToAdd<>, 53 53 public ast::WithShortCircuiting { … … 232 232 233 233 // -------------------------------------------------------------------------- 234 void AutogenerateRoutines _new::previsit( const ast::EnumDecl * enumDecl ) {234 void AutogenerateRoutines::previsit( const ast::EnumDecl * enumDecl ) { 235 235 // Must visit children (enum constants) to add them to the symbol table. 236 236 if ( !enumDecl->body ) return; … … 249 249 } 250 250 251 void AutogenerateRoutines _new::previsit( const ast::StructDecl * structDecl ) {251 void AutogenerateRoutines::previsit( const ast::StructDecl * structDecl ) { 252 252 visit_children = false; 253 253 if ( !structDecl->body ) return; … … 265 265 } 266 266 267 void AutogenerateRoutines _new::previsit( const ast::UnionDecl * unionDecl ) {267 void AutogenerateRoutines::previsit( const ast::UnionDecl * unionDecl ) { 268 268 visit_children = false; 269 269 if ( !unionDecl->body ) return; … … 282 282 283 283 /// Generate ctor/dtors/assign for typedecls, e.g., otype T = int *; 284 void AutogenerateRoutines _new::previsit( const ast::TypeDecl * typeDecl ) {284 void AutogenerateRoutines::previsit( const ast::TypeDecl * typeDecl ) { 285 285 if ( !typeDecl->base ) return; 286 286 … … 290 290 } 291 291 292 void AutogenerateRoutines _new::previsit( const ast::TraitDecl * ) {292 void AutogenerateRoutines::previsit( const ast::TraitDecl * ) { 293 293 // Ensure that we don't add assignment ops for types defined as part of the trait 294 294 visit_children = false; 295 295 } 296 296 297 void AutogenerateRoutines _new::previsit( const ast::FunctionDecl * ) {297 void AutogenerateRoutines::previsit( const ast::FunctionDecl * ) { 298 298 // Track whether we're currently in a function. 299 299 // Can ignore function type idiosyncrasies, because function type can never … … 302 302 } 303 303 304 void AutogenerateRoutines _new::postvisit( const ast::FunctionDecl * ) {304 void AutogenerateRoutines::postvisit( const ast::FunctionDecl * ) { 305 305 functionNesting -= 1; 306 306 } … … 521 521 const ast::Expr * src, const ast::ObjectDecl * field, 522 522 ast::FunctionDecl * func, SymTab::LoopDirection direction ) { 523 InitTweak::InitExpander _newsrcParam( src );523 InitTweak::InitExpander srcParam( src ); 524 524 // Assign to destination. 525 525 ast::MemberExpr * dstSelect = new ast::MemberExpr( … … 795 795 796 796 void autogenerateRoutines( ast::TranslationUnit & translationUnit ) { 797 ast::Pass<AutogenerateRoutines _new>::run( translationUnit );797 ast::Pass<AutogenerateRoutines>::run( translationUnit ); 798 798 } 799 799
Note: See TracChangeset
for help on using the changeset viewer.