This is the mail archive of the 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: [RFA PATCH 3/3 V3] Testcase for pascal/17815

On 01/23/2015 12:20 AM, Pierre Muller wrote:
> Hi Pedro,
>> -----Message d'origine-----
>> De : [mailto:gdb-patches-
>>] De la part de Pedro Alves
>> Envoyé : jeudi 22 janvier 2015 13:46
>> À : Pierre Muller
>> Cc : 'gdb-patches'
>> Objet : Re: [RFA PATCH 3/3] Testcase for pascal/17815
>> Thanks for adding the test case.
>> On 01/09/2015 04:18 PM, Pierre Muller wrote:
>>>   This adds the testcase for pascal/17815 bug report.
>>> gdb/testsuite/Changelog entry:
>>> 2015-01-09  Pierre Muller  <>
>>> 	gdb.pascal/gdb17815.pas: New file.
>>> 	gdb.pascal/gdb17815.exp: New file.
>> Missing '*'. 
>   Fixed below.
>> Can you please pick a more descriptive name for the file?
>> One that suggests what's being tested, rather than a bug
>> number is ideal.  E.g., gdb.pascal/case-insensitive.{exp|pas}.
>   I used your suggestion, but this is not
> really a general case insensitiveness test...

You mean, it's just for symbols, rather than filesystems, etc?
gdb.pascal/case-insensitive-symbols.{exp|pas} would be my
suggestion then.  But these are just suggestions.  Feel free to
pick something else.

>   No, I tried and using runto_main,
> I got only failures, because it apparently did not stop
> at all on the breakpoint set earlier...
> Is there some code inside runto_main that
> deleted previously installed breakpoints?

Yes, it's the first thing runto_main -> runto does.

Why not just set the breakpoints after reaching main?

Or simpler still, use "runto $foo" directly, like:

set bp_location [gdb_get_line_number "set breakpoint here"]
if { ![runto ${srcfile}:${bp_location}] } {
    return 0

Or simpler still, just:

if { ![runto "check"] } {
    return 0

Assuming that to set a breakpoint on the "check" function,
you'd do "break check" in GDB.  If not, replace "check" with
whatever linespec would be used instead.

The patch looks good to me.

Pedro Alves

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