diff options
author | Jakub Jelinek <jakub@redhat.com> | 2019-08-09 09:23:03 +0200 |
---|---|---|
committer | Jakub Jelinek <jakub@gcc.gnu.org> | 2019-08-09 09:23:03 +0200 |
commit | 2c3b8badaac235ce78ce22ac7582346d16118987 (patch) | |
tree | 46f3346aa8d08711f83cb6e66e4fa9b511045998 /gcc/cp | |
parent | 5dd6b2daae47fc9b6d8802391cde4c4819c82564 (diff) | |
download | gcc-2c3b8badaac235ce78ce22ac7582346d16118987.zip gcc-2c3b8badaac235ce78ce22ac7582346d16118987.tar.gz gcc-2c3b8badaac235ce78ce22ac7582346d16118987.tar.bz2 |
re PR c/91401 (schedule + dist_schedule clauses rejected on distribute parallel for)
PR c/91401
c/
* c-parser.c (c_parser_omp_clause_dist_schedule): Fix up typos in the
check_no_duplicate_clause call. Comment it out, instead emit a
warning for duplicate dist_schedule clauses.
cp/
* parser.c (cp_parser_omp_clause_dist_schedule): Comment out the
check_no_duplicate_clause call, instead emit a warning for duplicate
dist_schedule clauses.
testsuite/
* c-c++-common/gomp/pr91401-1.c: New test.
* c-c++-common/gomp/pr91401-2.c: New test.
From-SVN: r274226
Diffstat (limited to 'gcc/cp')
-rw-r--r-- | gcc/cp/ChangeLog | 7 | ||||
-rw-r--r-- | gcc/cp/parser.c | 6 |
2 files changed, 11 insertions, 2 deletions
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index 5b0bf2b..93b6e5a 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,3 +1,10 @@ +2019-08-09 Jakub Jelinek <jakub@redhat.com> + + PR c/91401 + * parser.c (cp_parser_omp_clause_dist_schedule): Comment out the + check_no_duplicate_clause call, instead emit a warning for duplicate + dist_schedule clauses. + 2019-08-08 Paolo Carlini <paolo.carlini@oracle.com> * decl.c (grokdeclarator): Use id_loc and EXPR_LOCATION in diff --git a/gcc/cp/parser.c b/gcc/cp/parser.c index 14b7240..a2efb55 100644 --- a/gcc/cp/parser.c +++ b/gcc/cp/parser.c @@ -35258,8 +35258,10 @@ cp_parser_omp_clause_dist_schedule (cp_parser *parser, tree list, else if (!cp_parser_require (parser, CPP_CLOSE_PAREN, RT_COMMA_CLOSE_PAREN)) goto resync_fail; - check_no_duplicate_clause (list, OMP_CLAUSE_DIST_SCHEDULE, "dist_schedule", - location); + /* check_no_duplicate_clause (list, OMP_CLAUSE_DIST_SCHEDULE, + "dist_schedule", location); */ + if (omp_find_clause (list, OMP_CLAUSE_DIST_SCHEDULE)) + warning_at (location, 0, "too many %qs clauses", "dist_schedule"); OMP_CLAUSE_CHAIN (c) = list; return c; |