aboutsummaryrefslogtreecommitdiff
path: root/gcc/objc
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/objc')
-rw-r--r--gcc/objc/ChangeLog6
-rw-r--r--gcc/objc/objc-act.c3
-rw-r--r--gcc/objc/objc-gnu-runtime-abi-01.c2
3 files changed, 9 insertions, 2 deletions
diff --git a/gcc/objc/ChangeLog b/gcc/objc/ChangeLog
index 4936900..03327a5 100644
--- a/gcc/objc/ChangeLog
+++ b/gcc/objc/ChangeLog
@@ -1,3 +1,9 @@
+2015-06-05 Aldy Hernandez <aldyh@redhat.com>
+
+ * objc-act.c (objc_write_global_declarations): Adjust comment.
+ * objc-gnu-runtime-abi-01.c (build_selector_table_decl): Set
+ TREE_USED bit.
+
2015-06-04 Andrew MacLeod <amacleod@redhat.com>
* objc-act.c: Adjust includes for restructured coretypes.h.
diff --git a/gcc/objc/objc-act.c b/gcc/objc/objc-act.c
index 1d343eb..f42f679 100644
--- a/gcc/objc/objc-act.c
+++ b/gcc/objc/objc-act.c
@@ -435,8 +435,7 @@ objc_init (void)
return true;
}
-/* This is called automatically (at the very end of compilation) by
- c_write_global_declarations and cp_write_global_declarations. */
+/* This is called at the end of parsing by the C/C++ parsers. */
void
objc_write_global_declarations (void)
{
diff --git a/gcc/objc/objc-gnu-runtime-abi-01.c b/gcc/objc/objc-gnu-runtime-abi-01.c
index 7352c21..6986645 100644
--- a/gcc/objc/objc-gnu-runtime-abi-01.c
+++ b/gcc/objc/objc-gnu-runtime-abi-01.c
@@ -497,6 +497,8 @@ build_selector_table_decl (void)
temp = build_array_type (objc_selector_template, NULL_TREE);
UOBJC_SELECTOR_TABLE_decl = start_var_decl (temp, "_OBJC_SELECTOR_TABLE");
+ /* Squash `defined but not used' warning check_global_declaration. */
+ TREE_USED (UOBJC_SELECTOR_TABLE_decl) = 1;
OBJCMETA (UOBJC_SELECTOR_TABLE_decl, objc_meta, meta_base);
}