Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/Concurrency/Keywords.cc

    rba3706f rbd41764  
    3838
    3939namespace Concurrency {
     40
     41        namespace {
     42                const std::list<Label> noLabels;
     43                const std::list< Attribute * > noAttributes;
     44                Type::StorageClasses noStorage;
     45                Type::Qualifiers noQualifiers;
     46        }
     47
    4048        //=============================================================================================
    4149        // Pass declarations
     
    288296                ObjectDecl * this_decl = new ObjectDecl(
    289297                        "this",
    290                         noStorageClasses,
     298                        noStorage,
    291299                        LinkageSpec::Cforall,
    292300                        nullptr,
     
    305313                        new ObjectDecl(
    306314                                "ret",
    307                                 noStorageClasses,
     315                                noStorage,
    308316                                LinkageSpec::Cforall,
    309317                                nullptr,
     
    338346                        main_decl = new FunctionDecl(
    339347                                "main",
    340                                 noStorageClasses,
     348                                noStorage,
    341349                                LinkageSpec::Cforall,
    342350                                main_type,
     
    355363                ObjectDecl * field = new ObjectDecl(
    356364                        field_name,
    357                         noStorageClasses,
     365                        noStorage,
    358366                        LinkageSpec::Cforall,
    359367                        nullptr,
     
    371379
    372380        void ConcurrentSueKeyword::addRoutines( ObjectDecl * field, FunctionDecl * func ) {
    373                 CompoundStmt * statement = new CompoundStmt();
     381                CompoundStmt * statement = new CompoundStmt( noLabels );
    374382                statement->push_back(
    375383                        new ReturnStmt(
     384                                noLabels,
    376385                                new AddressExpr(
    377386                                        new MemberExpr(
     
    479488                ObjectDecl * monitors = new ObjectDecl(
    480489                        "__monitor",
    481                         noStorageClasses,
     490                        noStorage,
    482491                        LinkageSpec::Cforall,
    483492                        nullptr,
     
    500509                // monitor_guard_t __guard = { __monitors, #, func };
    501510                body->push_front(
    502                         new DeclStmt( new ObjectDecl(
     511                        new DeclStmt( noLabels, new ObjectDecl(
    503512                                "__guard",
    504                                 noStorageClasses,
     513                                noStorage,
    505514                                LinkageSpec::Cforall,
    506515                                nullptr,
     
    521530
    522531                //monitor_desc * __monitors[] = { get_monitor(a), get_monitor(b) };
    523                 body->push_front( new DeclStmt( monitors) );
     532                body->push_front( new DeclStmt( noLabels, monitors) );
    524533        }
    525534
     
    527536                ObjectDecl * monitors = new ObjectDecl(
    528537                        "__monitors",
    529                         noStorageClasses,
     538                        noStorage,
    530539                        LinkageSpec::Cforall,
    531540                        nullptr,
     
    560569                // monitor_guard_t __guard = { __monitors, #, func };
    561570                body->push_front(
    562                         new DeclStmt( new ObjectDecl(
     571                        new DeclStmt( noLabels, new ObjectDecl(
    563572                                "__guard",
    564                                 noStorageClasses,
     573                                noStorage,
    565574                                LinkageSpec::Cforall,
    566575                                nullptr,
     
    582591
    583592                //monitor_desc * __monitors[] = { get_monitor(a), get_monitor(b) };
    584                 body->push_front( new DeclStmt( monitors) );
     593                body->push_front( new DeclStmt( noLabels, monitors) );
    585594        }
    586595
     
    622631                stmt->push_back(
    623632                        new ExprStmt(
     633                                noLabels,
    624634                                new UntypedExpr(
    625635                                        new NameExpr( "__thrd_start" ),
Note: See TracChangeset for help on using the changeset viewer.