summaryrefslogtreecommitdiff
path: root/gcc/c-decl.c
diff options
context:
space:
mode:
authorjason <jason@138bc75d-0d04-0410-961f-82ee72b054a4>2011-07-22 19:59:49 +0000
committerjason <jason@138bc75d-0d04-0410-961f-82ee72b054a4>2011-07-22 19:59:49 +0000
commit272822520857a2399e4cdd0d851aacb431e64bcc (patch)
tree316fb84969a5bd89637c30710f3f154a8baf6605 /gcc/c-decl.c
parent267001d77c9e04699c7a4055592c8777329dfdd3 (diff)
downloadgcc-272822520857a2399e4cdd0d851aacb431e64bcc.tar.gz
PR c++/30112
gcc/c-family/ * c-common.h: Declare c_linkage_bindings. * c-pragma.c (handle_pragma_redefine_extname): Use it. gcc/ * c-decl.c (c_linkage_bindings): Define. gcc/cp/ * decl.c (cp_finish_decl): Apply pragma redefine_extname in other namespaces as well. * name-lookup.c (c_linkage_bindings): Define. (lookup_extern_c_fun_in_all_ns): Rename from lookup_extern_c_fun_binding_in_all_ns. Return tree. (pushdecl_maybe_friend_1): Adjust. Copy DECL_ASSEMBLER_NAME. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@176650 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/c-decl.c')
-rw-r--r--gcc/c-decl.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/gcc/c-decl.c b/gcc/c-decl.c
index 3ed3c46e64c..33d2615bc22 100644
--- a/gcc/c-decl.c
+++ b/gcc/c-decl.c
@@ -8501,6 +8501,14 @@ identifier_global_value (tree t)
return 0;
}
+/* In C, the only C-linkage public declaration is at file scope. */
+
+tree
+c_linkage_bindings (tree name)
+{
+ return identifier_global_value (name);
+}
+
/* Record a builtin type for C. If NAME is non-NULL, it is the name used;
otherwise the name is found in ridpointers from RID_INDEX. */