public inbox for gdb-patches@sourceware.org
 help / color / mirror / Atom feed
From: Simon Marchi <simon.marchi@polymtl.ca>
To: Keith Seitz <keiths@redhat.com>, George Barrett <bob@bob131.so>,
	gdb-patches@sourceware.org
Subject: Re: [PING**4] [PATCH] Guile: temporary breakpoints
Date: Tue, 8 Jun 2021 22:25:23 -0400	[thread overview]
Message-ID: <db4de71d-38b9-110b-4e91-420501a5da60@polymtl.ca> (raw)
In-Reply-To: <aec41501-f532-1908-0232-a5f9676ce957@polymtl.ca>



On 2021-06-08 10:21 p.m., Simon Marchi via Gdb-patches wrote:
> On 2021-06-08 5:00 p.m., Keith Seitz via Gdb-patches wrote:
>> Hi,
>>
>> I apologize that no one has yet reviewed your patch, which certainly seems
>> like something we would want. Feature parity between Python and Guile can
>> only be good for users.
>>
>> I've nearly no experience with Guile, but looking this over, this patch looks
>> pretty straightforward, but I do have some small suggestions/requests below.
>>
>> Otherwise, I would like to recommend that a maintainer approve this.
>> [I am not someone that can grant permission to push to the repo.]
>>
>> Thanks again for the patch *and* your patience.
>>
>> Keith
> 
> Thanks for looking at it Keith, it helps a lot.
> 
>>>>>>> +proc_with_prefix test_bkpt_temporary { } {
>>>>>>> +    global srcfile testfile hex decimal
>>>>>>> +
>>>>>>> +    with_test_prefix test_bkpt_temporary {
>>>>>>> +	# Start with a fresh gdb.
>>>>>>> +	clean_restart ${testfile}
>>>>>>> +
>>>>>>> +	if ![gdb_guile_runto_main] then {
>>>>>>> +	    fail "cannot run to main."
>>
>> For consistency, please use "if {expr} {".
>>
>> This result should probably be 'untested "cannot run to main"' instead
>> of simply a fail. [Taken straight from gdb.base/template.exp.]
> 
> Perhaps it was a mistake to use untested in gdb.base/template.exp?
> 
> There are more instances of using "fail":
> 
> 
>     $ ag -A 2 runto_main | grep untested | wc -l
>     198
>     $ ag -A 2 runto_main | grep fail | wc -l
>     555
> 
> ... and it makes more sense to me to use "fail".  If I introduce a bug
> that prevents running to main to work, untested would be easier to miss
> than fail.
> 
> Otherwise, I don't have the original context to quote but where it says:
> 
>   return scm_from_bool (bp_smob->bp->disposition == disp_del ||
> 			bp_smob->bp->disposition == disp_del_at_next_stop);
> 
> put the || operator on the next line:
> 
>   return scm_from_bool (bp_smob->bp->disposition == disp_del
> 			|| bp_smob->bp->disposition == disp_del_at_next_stop);
> 
> 
> Other than that, the patch LGTM after taking Keith's feedback in
> consideration.
> 
> Simon
> 

Oh also, we probably need a short NEWS entry for this.

Simon

  reply	other threads:[~2021-06-09  2:25 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-04-25 18:56 George Barrett
2021-05-11 18:23 ` [PING] " George Barrett
2021-05-19  5:15   ` [PING**2] " George Barrett
2021-05-27 16:36     ` [PING**3] " George Barrett
2021-06-08 19:57       ` [PING**4] " George Barrett
2021-06-08 21:00         ` Keith Seitz
2021-06-09  2:21           ` Simon Marchi
2021-06-09  2:25             ` Simon Marchi [this message]
2021-06-09  2:42               ` George Barrett

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=db4de71d-38b9-110b-4e91-420501a5da60@polymtl.ca \
    --to=simon.marchi@polymtl.ca \
    --cc=bob@bob131.so \
    --cc=gdb-patches@sourceware.org \
    --cc=keiths@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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).