summaryrefslogtreecommitdiff
path: root/gcc/c-decl.c
diff options
context:
space:
mode:
authorsteven <steven@138bc75d-0d04-0410-961f-82ee72b054a4>2010-05-28 23:13:18 +0000
committersteven <steven@138bc75d-0d04-0410-961f-82ee72b054a4>2010-05-28 23:13:18 +0000
commit6ad8abad783af88a9591b967932a810347637b4e (patch)
tree10c0cab781166ed9521df083f46d8b46e2cb8deb /gcc/c-decl.c
parent8d46e4d23573f66b434fc331aa90a7a42f71bef8 (diff)
downloadgcc-6ad8abad783af88a9591b967932a810347637b4e.tar.gz
gcc/ChangeLog:
* c-common.h: Add FIXME for awkward split of c_register_addr_space. * c-common.c (c_register_addr_space): Remove here. * c-decl.c (c_register_addr_space): Re-add here. cp/ChangeLog: * tree.c (c_register_addr_space): Add stub. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@160006 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/c-decl.c')
-rw-r--r--gcc/c-decl.c19
1 files changed, 19 insertions, 0 deletions
diff --git a/gcc/c-decl.c b/gcc/c-decl.c
index a49694007d2..82632d99345 100644
--- a/gcc/c-decl.c
+++ b/gcc/c-decl.c
@@ -9672,4 +9672,23 @@ c_write_global_declarations (void)
ext_block = NULL;
}
+/* Register reserved keyword WORD as qualifier for address space AS. */
+
+void
+c_register_addr_space (const char *word, addr_space_t as)
+{
+ int rid = RID_FIRST_ADDR_SPACE + as;
+ tree id;
+
+ /* Address space qualifiers are only supported
+ in C with GNU extensions enabled. */
+ if (c_dialect_objc () || flag_no_asm)
+ return;
+
+ id = get_identifier (word);
+ C_SET_RID_CODE (id, rid);
+ C_IS_RESERVED_WORD (id) = 1;
+ ridpointers [rid] = id;
+}
+
#include "gt-c-decl.h"