diff options
author | Richard Guenther <rguenther@suse.de> | 2009-08-07 08:54:53 +0000 |
---|---|---|
committer | Richard Biener <rguenth@gcc.gnu.org> | 2009-08-07 08:54:53 +0000 |
commit | 60419cc8912bb1b64298c8b83c55b071b0717a39 (patch) | |
tree | 2bd7ee4870a404eae65aa88e36ba3a72231f2af6 /gcc/tree-ssa.c | |
parent | 685b0d134d7e7dc210a85bdfbd189c9f69f82a62 (diff) | |
download | gcc-60419cc8912bb1b64298c8b83c55b071b0717a39.zip gcc-60419cc8912bb1b64298c8b83c55b071b0717a39.tar.gz gcc-60419cc8912bb1b64298c8b83c55b071b0717a39.tar.bz2 |
tree-ssa.c (useless_type_conversion_p_1): Only for types that require structural equality defer to the langhook.
2009-08-07 Richard Guenther <rguenther@suse.de>
* tree-ssa.c (useless_type_conversion_p_1): Only for types
that require structural equality defer to the langhook.
From-SVN: r150559
Diffstat (limited to 'gcc/tree-ssa.c')
-rw-r--r-- | gcc/tree-ssa.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/gcc/tree-ssa.c b/gcc/tree-ssa.c index 0b4cc96..ddd4cfb 100644 --- a/gcc/tree-ssa.c +++ b/gcc/tree-ssa.c @@ -1073,11 +1073,11 @@ useless_type_conversion_p_1 (tree outer_type, tree inner_type) else if (AGGREGATE_TYPE_P (inner_type) && TREE_CODE (inner_type) == TREE_CODE (outer_type)) { - /* ??? This seems to be necessary even for aggregates that don't - have TYPE_STRUCTURAL_EQUALITY_P set. */ + if (TYPE_STRUCTURAL_EQUALITY_P (outer_type) + || TYPE_STRUCTURAL_EQUALITY_P (inner_type)) + return lang_hooks.types_compatible_p (inner_type, outer_type); - /* ??? This should eventually just return false. */ - return lang_hooks.types_compatible_p (inner_type, outer_type); + return false; } return false; |