semantics.c (handle_omp_array_sections_1): Don't ICE when processing_template_decl...
authorJakub Jelinek <jakub@redhat.com>
Fri, 17 Jun 2016 13:35:42 +0000 (15:35 +0200)
committerJakub Jelinek <jakub@gcc.gnu.org>
Fri, 17 Jun 2016 13:35:42 +0000 (15:35 +0200)
commit9b6a8d0fd1ab985408a389809fdaafdc09d2d165
treefa79a694cfe82656768dfc101f5b35d41f9fea27
parent6ffccb58d64ee2383365ab4e0eb949b780dd3f14
semantics.c (handle_omp_array_sections_1): Don't ICE when processing_template_decl when checking for bitfields and unions.

* semantics.c (handle_omp_array_sections_1): Don't ICE when
processing_template_decl when checking for bitfields and unions.
Look through REFERENCE_REF_P as base of COMPONENT_REF.
(finish_omp_clauses): Look through REFERENCE_REF_P even for
array sections with COMPONENT_REF bases.

* testsuite/libgomp.c++/target-21.C: New test.

From-SVN: r237554
gcc/cp/ChangeLog
gcc/cp/semantics.c
libgomp/ChangeLog
libgomp/testsuite/libgomp.c++/target-21.C [new file with mode: 0644]