public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Iain Sandoe <iain@sandoe.co.uk>
To: GCC Patches <gcc-patches@gcc.gnu.org>
Subject: [pushed] Ojective-C, Darwin : Adjust category superclass ref names  (NFC).
Date: Sun, 11 Oct 2020 11:38:09 +0100	[thread overview]
Message-ID: <B8BF052C-C67D-4B9B-880D-06A9248FAC8E@sandoe.co.uk> (raw)

Hi,

Make the order of the class and superclass match the metadata
order from clang.  Makes it easier to compare produced meta-
data between implementations.

tested across the Darwin range and on x86_64-linux,
pushed to master
thanks
Iain

gcc/objc/ChangeLog:

	* objc-next-runtime-abi-02.c
	(next_runtime_abi_02_category_decl): Adjust category
	superclass name ordering.
---
 gcc/objc/objc-next-runtime-abi-02.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/gcc/objc/objc-next-runtime-abi-02.c b/gcc/objc/objc-next-runtime-abi-02.c
index 3a308975325..92ede0325e9 100644
--- a/gcc/objc/objc-next-runtime-abi-02.c
+++ b/gcc/objc/objc-next-runtime-abi-02.c
@@ -980,9 +980,9 @@ next_runtime_abi_02_category_decl (tree klass)
 {
   tree decl;
   char buf[BUFSIZE];
-  snprintf (buf, BUFSIZE, "_OBJC_Category_%s_on_%s",
-	    IDENTIFIER_POINTER (CLASS_SUPER_NAME (klass)),
-	    IDENTIFIER_POINTER (CLASS_NAME (klass)));
+  snprintf (buf, BUFSIZE, "_OBJC_Category_%s_%s",
+	    IDENTIFIER_POINTER (CLASS_NAME (klass)),
+	    IDENTIFIER_POINTER (CLASS_SUPER_NAME (klass)));
   decl = start_var_decl (objc_v2_category_template, buf);
   OBJCMETA (decl, objc_meta, meta_category);
   return decl;
-- 
2.24.1



                 reply	other threads:[~2020-10-11 10:38 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=B8BF052C-C67D-4B9B-880D-06A9248FAC8E@sandoe.co.uk \
    --to=iain@sandoe.co.uk \
    --cc=gcc-patches@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).