mirror of
git://gcc.gnu.org/git/gcc.git
synced 2025-01-11 07:34:30 +08:00
[multiple changes]
2007-04-30 Andrew Pinski <andrew_pinski@playstation.sony.com> PR C++/31721 * tree.c (reconstruct_complex_type): Reconstruct a reference correctly. Also use the same mode for the pointer as the old pointer type. 2007-04-30 Andrew pinski <andrew_pinski@playstation.sony.com> PR C++/31721 * g++.dg/ext/vector7.C: New testcase. From-SVN: r124300
This commit is contained in:
parent
8f1a19e2c5
commit
ab44f2818c
@ -1,3 +1,10 @@
|
||||
2007-04-30 Andrew Pinski <andrew_pinski@playstation.sony.com>
|
||||
|
||||
PR C++/31721
|
||||
* tree.c (reconstruct_complex_type): Reconstruct a reference
|
||||
correctly.
|
||||
Also use the same mode for the pointer as the old pointer type.
|
||||
|
||||
2007-04-30 Francois-Xavier Coudert <coudert@clipper.ens.fr>
|
||||
|
||||
* doc/trouble.texi (Interoperation): Remove note about Ultrix
|
||||
|
@ -1,4 +1,9 @@
|
||||
2007-04-29 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
|
||||
2007-04-30 Andrew pinski <andrew_pinski@playstation.sony.com>
|
||||
|
||||
PR C++/31721
|
||||
* g++.dg/ext/vector7.C: New testcase.
|
||||
|
||||
2007-04-29 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
|
||||
|
||||
PR fortran/31591
|
||||
* gfortran.dg/bound_simplification_1.f90: New test.
|
||||
|
8
gcc/testsuite/g++.dg/ext/vector7.C
Normal file
8
gcc/testsuite/g++.dg/ext/vector7.C
Normal file
@ -0,0 +1,8 @@
|
||||
// { dg-options "" }
|
||||
// { dg-do compile }
|
||||
// PR C++/31721 and PR 14217
|
||||
// the attribute vector_size would change a reference type into a pointer type which was wrong.
|
||||
|
||||
#define vector __attribute__((__vector_size__(16) ))
|
||||
vector int b;
|
||||
vector int &a = b;
|
13
gcc/tree.c
13
gcc/tree.c
@ -7236,11 +7236,18 @@ tree
|
||||
reconstruct_complex_type (tree type, tree bottom)
|
||||
{
|
||||
tree inner, outer;
|
||||
|
||||
if (POINTER_TYPE_P (type))
|
||||
|
||||
if (TREE_CODE (type) == POINTER_TYPE)
|
||||
{
|
||||
inner = reconstruct_complex_type (TREE_TYPE (type), bottom);
|
||||
outer = build_pointer_type (inner);
|
||||
outer = build_pointer_type_for_mode (inner, TYPE_MODE (type),
|
||||
TYPE_REF_CAN_ALIAS_ALL (type));
|
||||
}
|
||||
else if (TREE_CODE (type) == REFERENCE_TYPE)
|
||||
{
|
||||
inner = reconstruct_complex_type (TREE_TYPE (type), bottom);
|
||||
outer = build_reference_type_for_mode (inner, TYPE_MODE (type),
|
||||
TYPE_REF_CAN_ALIAS_ALL (type));
|
||||
}
|
||||
else if (TREE_CODE (type) == ARRAY_TYPE)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user