This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] [PR 9514] Fixing parse error for "pointer to a function pointer"


On Thu, Sep 29, 2011 at 4:40 PM, Pedro Alves <pedro@codesourcery.com> wrote:
> On Thursday 29 September 2011 11:44:04, Abhijit Halder wrote:
>> On Thu, Sep 29, 2011 at 4:10 PM, Abhijit Halder
>> <abhijit.k.halder@gmail.com> wrote:
>> > Hi all,
>> >
>> > The current patch is to fix the issue defined in PR 9514. There's no
>> > regression. Please review this.
>> >
>> > Thanks,
>> > Abhijit Halder
>> >
>>
>> Oops! The ChangeLog is incorrect. Correcting the same.
>
> Please always post both ChangeLog and patch together. ?It's
> practically 0 work to repost the whole thing instead of just a
> part, while having all pieces together is easier for review, as
> it avoids the reviewer, not being as familiar with the patches
> as you, having to hunt for the pieces. ?Also, please always try
> to give explanations of what was wrong in the current code, and how
> you're fixing the problem. ?If you found a problem with an earlier
> patch attempt, it's quite useful to know why that earlier patch didn't
> work. ?If a reviewer will need to try out a patch and go through
> the same debug/thought process you had to go throught when writting
> the patch, then it's more likely a patch will go by unreviewed
> for longer. ?In a nutshell, your job is to make it easy to get an OK.
>
> --
> Pedro Alves
>

Yes the got the point.

I am re-submitting the whole thing once again for ease of review.

Thanks,
Abhijit Halder

Attachment: ChangeLog.txt
Description: Text document

Index: gdb/c-exp.y
===================================================================
RCS file: /cvs/src/src/gdb/c-exp.y,v
retrieving revision 1.82
diff -a -p -u -r1.82 c-exp.y
--- gdb/c-exp.y	6 May 2011 14:12:17 -0000	1.82
+++ gdb/c-exp.y	29 Sep 2011 10:26:20 -0000
@@ -926,6 +926,8 @@ const_or_volatile_or_space_identifier: 
 
 abs_decl:	'*'
 			{ push_type (tp_pointer); $$ = 0; }
+	|	abs_decl '*'
+			{ push_type (tp_pointer); $$ = $1; }
 	|	'*' abs_decl
 			{ push_type (tp_pointer); $$ = $2; }
 	|	'&'

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]