re PR c++/35028 (ICE with strange ctor and firstprivate)
PR c++/35028 * cp-gimplify.c (cxx_omp_clause_apply_fn): Handle vararg copy ctors. * g++.dg/gomp/pr35028.C: New test. From-SVN: r132426
This commit is contained in:
parent
edb6000e37
commit
d2ee546fd6
|
@ -1,5 +1,8 @@
|
|||
2008-02-19 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR c++/35028
|
||||
* cp-gimplify.c (cxx_omp_clause_apply_fn): Handle vararg copy ctors.
|
||||
|
||||
PR c++/34964
|
||||
PR c++/35244
|
||||
* semantics.c (finish_omp_threadprivate): Do nothing for error_operand_p
|
||||
|
|
|
@ -844,7 +844,8 @@ cxx_omp_clause_apply_fn (tree fn, tree arg1, tree arg2)
|
|||
if (arg2)
|
||||
argarray[i++] = p2;
|
||||
/* Handle default arguments. */
|
||||
for (parm = defparm; parm != void_list_node; parm = TREE_CHAIN (parm), i++)
|
||||
for (parm = defparm; parm && parm != void_list_node;
|
||||
parm = TREE_CHAIN (parm), i++)
|
||||
argarray[i] = convert_default_arg (TREE_VALUE (parm),
|
||||
TREE_PURPOSE (parm), fn, i);
|
||||
t = build_call_a (fn, i, argarray);
|
||||
|
@ -875,7 +876,7 @@ cxx_omp_clause_apply_fn (tree fn, tree arg1, tree arg2)
|
|||
if (arg2)
|
||||
argarray[i++] = build_fold_addr_expr (arg2);
|
||||
/* Handle default arguments. */
|
||||
for (parm = defparm; parm != void_list_node;
|
||||
for (parm = defparm; parm && parm != void_list_node;
|
||||
parm = TREE_CHAIN (parm), i++)
|
||||
argarray[i] = convert_default_arg (TREE_VALUE (parm),
|
||||
TREE_PURPOSE (parm),
|
||||
|
|
|
@ -1,5 +1,8 @@
|
|||
2008-02-19 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR c++/35028
|
||||
* g++.dg/gomp/pr35028.C: New test.
|
||||
|
||||
PR c++/34964
|
||||
PR c++/35244
|
||||
* gcc.dg/gomp/pr34964.c: New test.
|
||||
|
|
|
@ -0,0 +1,19 @@
|
|||
// PR c++/35028
|
||||
// { dg-do compile }
|
||||
// { dg-options "-fopenmp" }
|
||||
|
||||
struct A
|
||||
{
|
||||
A ();
|
||||
A (const A &, ...);
|
||||
~A ();
|
||||
A operator++ (int);
|
||||
};
|
||||
|
||||
void
|
||||
foo ()
|
||||
{
|
||||
A a;
|
||||
#pragma omp parallel firstprivate (a)
|
||||
a++;
|
||||
}
|
Loading…
Reference in New Issue