Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Sergio Durigan Junior <sergiodj@redhat.com>
To: GDB Patches <gdb-patches@sourceware.org>
Cc: Tom Tromey <tromey@redhat.com>,
	       Sergio Durigan Junior <sergiodj@redhat.com>
Subject: [PATCH v4 08/10] Objective-C language
Date: Sat, 22 Mar 2014 04:57:00 -0000	[thread overview]
Message-ID: <1395463432-29750-9-git-send-email-sergiodj@redhat.com> (raw)
In-Reply-To: <1395463432-29750-1-git-send-email-sergiodj@redhat.com>

Patch for the Objective-C language.  Since we don't have gdb/objc-exp.y
anymore, this only touches on the lang files.

2014-03-22  Sergio Durigan Junior  <sergiodj@redhat.com>

	* objc-lang.c (end_msglist): Add "struct parser_state" argument.
	* objc-lang.h: Forward declare "struct parser_state".
	(end_msglist): Add "struct parser_state" argument.
---
 gdb/objc-lang.c | 8 ++++----
 gdb/objc-lang.h | 3 ++-
 2 files changed, 6 insertions(+), 5 deletions(-)

diff --git a/gdb/objc-lang.c b/gdb/objc-lang.c
index 4327895..68f0d10 100644
--- a/gdb/objc-lang.c
+++ b/gdb/objc-lang.c
@@ -465,7 +465,7 @@ add_msglist(struct stoken *str, int addcolon)
 }
 
 int
-end_msglist(void)
+end_msglist (struct parser_state *ps)
 {
   int val = msglist_len;
   struct selname *sel = selname_chain;
@@ -475,12 +475,12 @@ end_msglist(void)
   selname_chain = sel->next;
   msglist_len = sel->msglist_len;
   msglist_sel = sel->msglist_sel;
-  selid = lookup_child_selector (parse_gdbarch, p);
+  selid = lookup_child_selector (parse_gdbarch (ps), p);
   if (!selid)
     error (_("Can't find selector \"%s\""), p);
-  write_exp_elt_longcst (selid);
+  write_exp_elt_longcst (ps, selid);
   xfree(p);
-  write_exp_elt_longcst (val);	/* Number of args */
+  write_exp_elt_longcst (ps, val);	/* Number of args */
   xfree(sel);
 
   return val;
diff --git a/gdb/objc-lang.h b/gdb/objc-lang.h
index 6ba576a..df1fe53 100644
--- a/gdb/objc-lang.h
+++ b/gdb/objc-lang.h
@@ -26,6 +26,7 @@ struct stoken;
 
 struct value;
 struct block;
+struct parser_state;
 
 extern CORE_ADDR lookup_objc_class     (struct gdbarch *gdbarch,
 					char *classname);
@@ -45,7 +46,7 @@ extern struct value *value_nsstring (struct gdbarch *gdbarch,
 /* for parsing Objective C */
 extern void start_msglist (void);
 extern void add_msglist (struct stoken *str, int addcolon);
-extern int end_msglist (void);
+extern int end_msglist (struct parser_state *);
 
 struct symbol *lookup_struct_typedef (char *name, const struct block *block,
 				      int noerr);
-- 
1.7.11.7


  parent reply	other threads:[~2014-03-22  4:57 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-03-22  4:44 [PATCH v4 00/10] Remove `expout*' globals from parser-defs.h Sergio Durigan Junior
2014-03-22  4:44 ` [PATCH v4 09/10] Pascal language Sergio Durigan Junior
2014-03-22  4:44 ` [PATCH v4 06/10] Java language Sergio Durigan Junior
2014-03-22  4:44 ` [PATCH v4 02/10] SystemTap integration Sergio Durigan Junior
2014-03-22  4:44 ` [PATCH v4 05/10] Fortran language Sergio Durigan Junior
2014-03-22  4:44 ` [PATCH v4 03/10] C language Sergio Durigan Junior
2014-03-22  4:44 ` [PATCH v4 10/10] Go programming language Sergio Durigan Junior
2014-03-22  4:44 ` [PATCH v4 04/10] Ada language Sergio Durigan Junior
2014-03-22  4:44 ` [PATCH v4 01/10] Language independent bits Sergio Durigan Junior
2014-03-22  4:57 ` Sergio Durigan Junior [this message]
2014-03-22  5:03 ` [PATCH v4 07/10] Modula-2 language Sergio Durigan Junior
2014-03-22 19:59   ` Gaius Mulley
2014-03-26 12:56 ` [PATCH v4 00/10] Remove `expout*' globals from parser-defs.h Joel Brobecker
2014-03-26 13:24   ` Sergio Durigan Junior
2014-03-27 22:25   ` Sergio Durigan Junior

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=1395463432-29750-9-git-send-email-sergiodj@redhat.com \
    --to=sergiodj@redhat.com \
    --cc=gdb-patches@sourceware.org \
    --cc=tromey@redhat.com \
    /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