Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Doug Evans <dje@google.com>
To: Sergio Durigan Junior <sergiodj@redhat.com>
Cc: GDB Patches <gdb-patches@sourceware.org>, Tom Tromey <tromey@redhat.com>
Subject: Re: [PATCH 10/10] Go programming language
Date: Wed, 13 Jun 2012 17:02:00 -0000	[thread overview]
Message-ID: <CADPb22QFjrTvG7UuK6aRte5eV7gTXuZ33Ok8pCFXx+hzKnA3eg@mail.gmail.com> (raw)
In-Reply-To: <m3d353u7ul.fsf@redhat.com>

On Tue, Jun 12, 2012 at 9:57 PM, Sergio Durigan Junior
<sergiodj@redhat.com> wrote:
> On Saturday, June 02 2012, I wrote:
>
>> Patch for the Go programming language.  Similar to the C language one.
>
> Ping.
>
> Doug, since you have put this code in, would you like to take a look
> just to be safe?

Righto.
There's some indentation issues with parameters.
If it's because they would otherwise exceed 80 cols, I'm not sure what
the convention is.

@@ -317,9 +322,10 @@ exp        :       exp '('
                          being accumulated by an outer function call.  */
                       { start_arglist (); }
               arglist ')'     %prec LEFT_ARROW
-                       { write_exp_elt_opcode (OP_FUNCALL);
-                         write_exp_elt_longcst ((LONGEST) end_arglist ());
-                         write_exp_elt_opcode (OP_FUNCALL); }
+                       { write_exp_elt_opcode (pstate, OP_FUNCALL);
+                         write_exp_elt_longcst (pstate,
+                                                (LONGEST) end_arglist ());
+                         write_exp_elt_opcode (pstate, OP_FUNCALL); }
       ;

 lcurly :       '{'

There's also the thought of making sure pstate is reset to NULL.

@@ -1587,14 +1603,20 @@ yylex (void)

  popping = 1;
  yylval = current.value;
-  return classify_name (expression_context_block);
+  return classify_name (pstate, expression_context_block);
 }

 int
-go_parse (void)
+go_parse (struct parser_state *par_state)
 {
  int result;
-  struct cleanup *back_to = make_cleanup (null_cleanup, NULL);
+  struct cleanup *back_to;
+
+  /* Setting up the parser state.  */
+  gdb_assert (par_state != NULL);
+  pstate = par_state;
+
+  back_to = make_cleanup (null_cleanup, NULL);

  make_cleanup_restore_integer (&yydebug);
  yydebug = parser_debug;

Other than that LGTM.


  reply	other threads:[~2012-06-13 17:02 UTC|newest]

Thread overview: 40+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-06-02 19:33 [PATCH 00/10] Remove `expout*' globals from parser-defs.h Sergio Durigan Junior
2012-06-02 19:33 ` [PATCH 02/10] SystemTap integration Sergio Durigan Junior
2012-06-04 20:23   ` Tom Tromey
2012-06-02 19:33 ` [PATCH 01/10] Language independent bits Sergio Durigan Junior
2012-06-04 20:20   ` Tom Tromey
2012-06-05  0:39     ` Sergio Durigan Junior
2012-06-02 19:34 ` [PATCH 03/10] C language Sergio Durigan Junior
2012-06-04  4:25   ` Doug Evans
2012-06-04  4:32     ` Sergio Durigan Junior
2012-06-04 20:32   ` Tom Tromey
2012-06-04 20:39     ` Sergio Durigan Junior
2012-06-04 20:42     ` Mark Kettenis
2012-06-04 20:49       ` Sergio Durigan Junior
2012-06-04 21:19         ` Mark Kettenis
2012-06-06 19:17           ` Tom Tromey
2012-06-02 20:23 ` [PATCH 10/10] Go programming language Sergio Durigan Junior
2012-06-13  4:58   ` Sergio Durigan Junior
2012-06-13 17:02     ` Doug Evans [this message]
2012-06-02 20:23 ` [PATCH 04/10] Ada language Sergio Durigan Junior
2012-06-13  4:57   ` Sergio Durigan Junior
2012-06-13 14:50     ` Joel Brobecker
2012-06-02 20:24 ` [PATCH 08/10] Objective-C language Sergio Durigan Junior
2012-06-13  4:59   ` Sergio Durigan Junior
2012-06-13 14:54     ` Joel Brobecker
2012-06-13 16:02     ` Tom Tromey
2012-06-02 20:24 ` [PATCH 05/10] Fortran language Sergio Durigan Junior
2012-06-13  4:59   ` Sergio Durigan Junior
2012-06-13 14:55     ` Joel Brobecker
2012-06-02 20:33 ` [PATCH 09/10] Pascal language Sergio Durigan Junior
2012-06-05  7:39   ` Pierre Muller
2012-06-02 20:33 ` [PATCH 07/10] Modula-2 language Sergio Durigan Junior
2012-06-13  4:59   ` Sergio Durigan Junior
2012-06-13 14:51     ` Joel Brobecker
2012-06-16 14:29       ` Gaius Mulley
2012-06-02 20:34 ` [PATCH 06/10] Java language Sergio Durigan Junior
2012-06-04 20:27   ` Tom Tromey
2012-06-05  0:35     ` Sergio Durigan Junior
2012-06-06 20:02       ` Tom Tromey
2012-06-07  0:57         ` Joel Brobecker
2012-06-04 20:38 ` [PATCH 00/10] Remove `expout*' globals from parser-defs.h Tom Tromey

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=CADPb22QFjrTvG7UuK6aRte5eV7gTXuZ33Ok8pCFXx+hzKnA3eg@mail.gmail.com \
    --to=dje@google.com \
    --cc=gdb-patches@sourceware.org \
    --cc=sergiodj@redhat.com \
    --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