aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorEric Botcazou <ebotcazou@adacore.com>2010-11-30 14:24:11 +0000
committerEric Botcazou <ebotcazou@gcc.gnu.org>2010-11-30 14:24:11 +0000
commit3f1faac1daefa83b6588424873c01f7d1370277d (patch)
tree7639bd81480a9751e8a38aca80f10e44584597bc /gcc
parent375a39e29b680700a6d1bff8ccd10242d8ddf21d (diff)
downloadgcc-3f1faac1daefa83b6588424873c01f7d1370277d.zip
gcc-3f1faac1daefa83b6588424873c01f7d1370277d.tar.gz
gcc-3f1faac1daefa83b6588424873c01f7d1370277d.tar.bz2
tree.c (build_range_type_1): Do not set TYPE_STRUCTURAL_EQUALITY_P because of self-referential bounds.
* tree.c (build_range_type_1): Do not set TYPE_STRUCTURAL_EQUALITY_P because of self-referential bounds. From-SVN: r167297
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ChangeLog5
-rw-r--r--gcc/tree.c6
2 files changed, 9 insertions, 2 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index a6099b8..0a325ce 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,8 @@
+2010-11-30 Eric Botcazou <ebotcazou@adacore.com>
+
+ * tree.c (build_range_type_1): Do not set TYPE_STRUCTURAL_EQUALITY_P
+ because of self-referential bounds.
+
2010-11-30 Joseph Myers <joseph@codesourcery.com>
* diagnostic-core.h: Include bversion.h.
diff --git a/gcc/tree.c b/gcc/tree.c
index 2f8d96e..d9a98f1 100644
--- a/gcc/tree.c
+++ b/gcc/tree.c
@@ -7110,9 +7110,11 @@ build_range_type_1 (tree type, tree lowval, tree highval, bool shared)
TYPE_USER_ALIGN (itype) = TYPE_USER_ALIGN (type);
if ((TYPE_MIN_VALUE (itype)
- && TREE_CODE (TYPE_MIN_VALUE (itype)) != INTEGER_CST)
+ && TREE_CODE (TYPE_MIN_VALUE (itype)) != INTEGER_CST
+ && !CONTAINS_PLACEHOLDER_P (TYPE_MIN_VALUE (itype)))
|| (TYPE_MAX_VALUE (itype)
- && TREE_CODE (TYPE_MAX_VALUE (itype)) != INTEGER_CST))
+ && TREE_CODE (TYPE_MAX_VALUE (itype)) != INTEGER_CST
+ && !CONTAINS_PLACEHOLDER_P (TYPE_MAX_VALUE (itype))))
{
/* Since we cannot reliably merge this type, we need to compare it using
structural equality checks. */