Changeset eba74ba for src/Parser/DeclarationNode.cc
- Timestamp:
- May 25, 2018, 2:51:06 PM (6 years ago)
- Branches:
- new-env, with_gc
- Children:
- cdc4d43
- Parents:
- 3ef35bd (diff), 58e822a (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/Parser/DeclarationNode.cc
r3ef35bd reba74ba 10 10 // Created On : Sat May 16 12:34:05 2015 11 11 // Last Modified By : Peter A. Buhr 12 // Last Modified On : Wed May 16 09:37:17201813 // Update Count : 107 012 // Last Modified On : Tue May 22 08:39:29 2018 13 // Update Count : 1074 14 14 // 15 15 … … 32 32 #include "SynTree/Type.h" // for Type, Type::StorageClasses, Type::... 33 33 #include "TypeData.h" // for TypeData, TypeData::Aggregate_t 34 #include "TypedefTable.h" // for TypedefTable , TypedefTable::kind_t...34 #include "TypedefTable.h" // for TypedefTable 35 35 36 36 class Initializer; … … 54 54 55 55 DeclarationNode::DeclarationNode() : 56 builtin( NoBuiltinType ), 56 57 type( nullptr ), 57 58 bitfieldWidth( nullptr ), … … 100 101 newnode->name = name ? new string( *name ) : nullptr; 101 102 103 newnode->builtin = NoBuiltinType; 102 104 newnode->type = maybeClone( type ); 103 105 newnode->storageClasses = storageClasses; … … 178 180 newnode->type->function.body = body; 179 181 180 // ignore unnamed routine declarations: void p( int (*)(int) );181 if ( newnode->name ) {182 typedefTable.addToEnclosingScope( *newnode->name, TypedefTable::ID );183 } // if184 185 182 if ( ret ) { 186 183 newnode->type->base = ret->type; … … 284 281 newnode->name = name; 285 282 newnode->enumeratorValue.reset( constant ); 286 typedefTable.addToEnclosingScope( *newnode->name, TypedefTable::ID );287 283 return newnode; 288 284 } // DeclarationNode::newEnumConstant … … 550 546 type->aggregate.params = q->type->forall; // make polymorphic type 551 547 // change implicit typedef from TYPEDEFname to TYPEGENname 552 typedefTable.changeKind( *type->aggregate.name, T ypedefTable::TG);548 typedefTable.changeKind( *type->aggregate.name, TYPEGENname ); 553 549 } // if 554 550 } else { // not polymorphic
Note: See TracChangeset
for help on using the changeset viewer.