aboutsummaryrefslogtreecommitdiff
path: root/gcc/c-aux-info.c
diff options
context:
space:
mode:
authorjsm28 <>2004-03-28 00:31:41 +0000
committerjsm28 <>2004-03-28 00:31:41 +0000
commit3f79bf08d50e15bf97f4a1cedf73b48db492e680 (patch)
tree3acc8edeeba4106c03dff66761ed088a39992358 /gcc/c-aux-info.c
parent7edfdbd35cafb4380d6411bbababaea080509d13 (diff)
* c-tree.h (C_DECL_REGISTER): New.
* c-aux-info.c (gen_decl), c-decl.c (objc_mark_locals_volatile, finish_decl, grokdeclarator, get_parm_info), c-typeck.c (build_array_ref, c_mark_addressable): Set and use it. * c-decl.c (grokdeclarator), c-typeck.c (c_mark_addressable): Allow structures with volatile fields to be declared register. Don't check TREE_ADDRESSABLE before warning about taking address of register. * c-decl.c (finish_decl): Don't allow structures with volatile fields to be placed in named register. * doc/trouble.texi: Remove reference to structures with volatile fields in registers. testsuite: * gcc.dg/940409-1.c: Remove XFAIL. * gcc.dg/reg-vol-struct-1.c: New test.
Diffstat (limited to 'gcc/c-aux-info.c')
-rw-r--r--gcc/c-aux-info.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/gcc/c-aux-info.c b/gcc/c-aux-info.c
index e785ade2239..2ef7324dd14 100644
--- a/gcc/c-aux-info.c
+++ b/gcc/c-aux-info.c
@@ -2,7 +2,7 @@
on information stored in GCC's tree structure. This code implements the
-aux-info option.
Copyright (C) 1989, 1991, 1994, 1995, 1997, 1998,
- 1999, 2000, 2003 Free Software Foundation, Inc.
+ 1999, 2000, 2003, 2004 Free Software Foundation, Inc.
Contributed by Ron Guilmette (rfg@segfault.us.com).
This file is part of GCC.
@@ -531,7 +531,7 @@ gen_decl (tree decl, int is_func_definition, formals_style style)
ret_val = affix_data_type (ret_val);
- if (TREE_CODE (decl) != FUNCTION_DECL && DECL_REGISTER (decl))
+ if (TREE_CODE (decl) != FUNCTION_DECL && C_DECL_REGISTER (decl))
ret_val = concat ("register ", ret_val, NULL);
if (TREE_PUBLIC (decl))
ret_val = concat ("extern ", ret_val, NULL);