aboutsummaryrefslogtreecommitdiff
path: root/gcc/tree.c
diff options
context:
space:
mode:
authorJason Merrill <jason@yorick.cygnus.com>1999-04-16 01:24:50 +0000
committerJason Merrill <jason@gcc.gnu.org>1999-04-15 21:24:50 -0400
commitace3c40a1fa95d3ef2b8607344e065fbf981c4c4 (patch)
treed70c3ec0b579ffee9c7bbe8c8334b63e8beddbfa /gcc/tree.c
parenta3638246e910ccf47e3ea86a6f99237c9420645e (diff)
downloadgcc-ace3c40a1fa95d3ef2b8607344e065fbf981c4c4.zip
gcc-ace3c40a1fa95d3ef2b8607344e065fbf981c4c4.tar.gz
gcc-ace3c40a1fa95d3ef2b8607344e065fbf981c4c4.tar.bz2
tree.c (valid_machine_attribute): If we're modifying the FUNCTION_TYPE within a POINTER_TYPE and we don't get a...
* tree.c (valid_machine_attribute): If we're modifying the FUNCTION_TYPE within a POINTER_TYPE and we don't get a decl, update the POINTER_TYPE. From-SVN: r26489
Diffstat (limited to 'gcc/tree.c')
-rw-r--r--gcc/tree.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/gcc/tree.c b/gcc/tree.c
index effc121..d259420 100644
--- a/gcc/tree.c
+++ b/gcc/tree.c
@@ -3439,6 +3439,13 @@ valid_machine_attribute (attr_name, attr_args, decl, type)
if (decl != 0)
TREE_TYPE (decl) = build_pointer_type (inner_type);
+ else
+ {
+ /* Clear TYPE_POINTER_TO for the old inner type, since
+ `type' won't be pointing to it anymore. */
+ TYPE_POINTER_TO (TREE_TYPE (type)) = NULL_TREE;
+ TREE_TYPE (type) = inner_type;
+ }
validated = 1;
}