Changeset 0a73148 for src/Parser
- Timestamp:
- Jul 13, 2018, 6:36:34 PM (6 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, no_list, persistent-indexer, pthread-emulation, qualifiedEnum
- Children:
- 6da49249
- Parents:
- 6b8b767 (diff), ae144af (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. - Location:
- src/Parser
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
src/Parser/DeclarationNode.cc
r6b8b767 r0a73148 1003 1003 // }; 1004 1004 if ( ! (extracted && decl->name == "" && ! anon) ) { 1005 if (decl->name == "") { 1006 if ( DeclarationWithType * dwt = dynamic_cast<DeclarationWithType *>( decl ) ) { 1007 if ( ReferenceToType * aggr = dynamic_cast<ReferenceToType *>( dwt->get_type() ) ) { 1008 if ( aggr->name.find("anonymous") == std::string::npos ) { 1009 bool isInline = false; 1010 if (cur->type->kind == TypeData::Aggregate || cur->type->kind == TypeData::AggregateInst) { 1011 if (cur->type->kind == TypeData::Aggregate) { 1012 isInline = cur->type->aggregate.inLine; 1013 } else { 1014 isInline = cur->type->aggInst.inLine; 1015 if ( TypeData * aggr = cur->type->aggInst.aggregate ) { 1016 if ( aggr->kind == TypeData::Aggregate ) { 1017 isInline = isInline || aggr->aggregate.inLine; 1018 } 1019 } 1020 } 1021 } 1022 if (! isInline) { 1023 // temporary: warn about anonymous member declarations of named types, since this conflicts with the syntax for the forward declaration of an anonymous type 1024 SemanticWarning( cur->location, Warning::AggrForwardDecl, aggr->name.c_str() ); 1025 } 1026 } 1027 } 1028 } 1029 } 1005 1030 decl->location = cur->location; 1006 1031 * out++ = decl; -
src/Parser/TypedefTable.cc
r6b8b767 r0a73148 5 5 // file "LICENCE" distributed with Cforall. 6 6 // 7 // TypedefTable.cc -- 7 // TypedefTable.cc -- 8 8 // 9 9 // Author : Peter A. Buhr 10 10 // Created On : Sat May 16 15:20:13 2015 11 11 // Last Modified By : Peter A. Buhr 12 // Last Modified On : Thu Jul 12 16:16:24 201813 // Update Count : 25 612 // Last Modified On : Fri Jul 13 18:35:54 2018 13 // Update Count : 257 14 14 // 15 15 -
src/Parser/parser.yy
r6b8b767 r0a73148 2307 2307 { $$ = new ExpressionNode( new TypeExpr( maybeMoveBuildType( $1 ) ) ); } 2308 2308 | assignment_expression 2309 { SemanticError( yylloc, toString("Expression generic parameters are currently unimplemented: ", $1->build()) ); $$ = nullptr; } 2309 2310 | type_list ',' type 2310 2311 { $$ = (ExpressionNode *)( $1->set_last( new ExpressionNode( new TypeExpr( maybeMoveBuildType( $3 ) ) ) ) ); } 2311 2312 | type_list ',' assignment_expression 2312 { $$ = (ExpressionNode *)( $1->set_last( $3 )); } 2313 { SemanticError( yylloc, toString("Expression generic parameters are currently unimplemented: ", $3->build()) ); $$ = nullptr; } 2314 // { $$ = (ExpressionNode *)( $1->set_last( $3 )); } 2313 2315 ; 2314 2316
Note: See TracChangeset
for help on using the changeset viewer.