Changeset bf2438c for src/Concurrency
- Timestamp:
- Jul 11, 2017, 3:06:40 PM (7 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, new-env, no_list, persistent-indexer, pthread-emulation, qualifiedEnum, resolv-new, with_gc
- Children:
- fcab269
- Parents:
- fab6ded
- Location:
- src/Concurrency
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
src/Concurrency/Keywords.cc
rfab6ded rbf2438c 17 17 #include "Concurrency/Keywords.h" 18 18 19 #include "InitTweak/InitTweak.h" 20 #include "SymTab/AddVisit.h" 21 #include "SynTree/Declaration.h" 22 #include "SynTree/Expression.h" 23 #include "SynTree/Initializer.h" 24 #include "SynTree/Statement.h" 25 #include "SynTree/Type.h" 26 #include "SynTree/Visitor.h" 19 #include <cassert> // for assert 20 #include <string> // for string, operator== 21 22 #include "Common/SemanticError.h" // for SemanticError 23 #include "Common/utility.h" // for deleteAll, map_range 24 #include "InitTweak/InitTweak.h" // for isConstructor 25 #include "Parser/LinkageSpec.h" // for Cforall 26 #include "SymTab/AddVisit.h" // for acceptAndAdd 27 #include "SynTree/Constant.h" // for Constant 28 #include "SynTree/Declaration.h" // for StructDecl, FunctionDecl, ObjectDecl 29 #include "SynTree/Expression.h" // for VariableExpr, ConstantExpr, Untype... 30 #include "SynTree/Initializer.h" // for SingleInit, ListInit, Initializer ... 31 #include "SynTree/Label.h" // for Label 32 #include "SynTree/Statement.h" // for CompoundStmt, DeclStmt, ExprStmt 33 #include "SynTree/Type.h" // for StructInstType, Type, PointerType 34 #include "SynTree/Visitor.h" // for Visitor, acceptAll 35 36 class Attribute; 27 37 28 38 namespace Concurrency { … … 322 332 if( needs_main ) { 323 333 FunctionType * main_type = new FunctionType( noQualifiers, false ); 324 334 325 335 main_type->get_parameters().push_back( this_decl->clone() ); 326 336 … … 361 371 void ConcurrentSueKeyword::addRoutines( ObjectDecl * field, FunctionDecl * func ) { 362 372 CompoundStmt * statement = new CompoundStmt( noLabels ); 363 statement->push_back( 373 statement->push_back( 364 374 new ReturnStmt( 365 375 noLabels, … … 386 396 //============================================================================================= 387 397 void MutexKeyword::visit(FunctionDecl* decl) { 388 Visitor::visit(decl); 398 Visitor::visit(decl); 389 399 390 400 std::list<DeclarationWithType*> mutexArgs = findMutexArgs( decl ); … … 510 520 void ThreadStarter::visit(FunctionDecl * decl) { 511 521 Visitor::visit(decl); 512 522 513 523 if( ! InitTweak::isConstructor(decl->get_name()) ) return; 514 524 … … 528 538 if( ! stmt ) return; 529 539 530 stmt->push_back( 540 stmt->push_back( 531 541 new ExprStmt( 532 542 noLabels, -
src/Concurrency/Keywords.h
rfab6ded rbf2438c 18 18 #define KEYWORDS_H 19 19 20 #include <list> 20 #include <list> // for list 21 21 22 #include "SynTree/Declaration.h" 22 class Declaration; 23 23 24 24 namespace Concurrency {
Note: See TracChangeset
for help on using the changeset viewer.