diff options
author | Jakub Jelinek <jakub@redhat.com> | 2021-01-20 08:35:20 +0100 |
---|---|---|
committer | Jakub Jelinek <jakub@redhat.com> | 2021-01-20 08:38:46 +0100 |
commit | 7ab1abf3b82a3bcfff9b7bc596166fef6a0d83ab (patch) | |
tree | 92927b40e79c805f8d83c7ae6bfbf8f6e0aa4d91 /gcc/tree-data-ref.c | |
parent | c05cdfb3f6335d55226cef7917a783498aa41244 (diff) | |
download | gcc-7ab1abf3b82a3bcfff9b7bc596166fef6a0d83ab.zip gcc-7ab1abf3b82a3bcfff9b7bc596166fef6a0d83ab.tar.gz gcc-7ab1abf3b82a3bcfff9b7bc596166fef6a0d83ab.tar.bz2 |
openmp: Don't ICE on detach clause with erroneous decl [PR98742]
Similarly to how we handle erroneous operands to e.g. allocate clause,
this change just removes those clauses instead of accessing TYPE_MAIN_VARIANT
of its type, which doesn't work on error_mark_node. Also, just for good
measure, bails out if TYPE_NAME is NULL.
2021-01-20 Jakub Jelinek <jakub@redhat.com>
PR c++/98742
* semantics.c (finish_omp_clauses) <case OMP_CLAUSE_DETACH>: If
error_operand_p, remove clause without further checking. Check
for non-NULL TYPE_NAME.
* c-c++-common/gomp/task-detach-2.c: New test.
Diffstat (limited to 'gcc/tree-data-ref.c')
0 files changed, 0 insertions, 0 deletions