Re: [PATCHv3 1/7] gdb: improve line number lookup around inline functions

Tom de Vries
2025-12-17T14:49:04Z

On 12/17/25 3:32 PM, Andrew Burgess wrote:
> Tom Tromey <tom@tromey.com> writes:
>
>>>>>>> "Andrew" == Andrew Burgess <aburgess@redhat.com> writes:
>>
>> Andrew> So my proposal is that the backward scan of the line table looking for
>> Andrew> an is-stmt entry should not be performed when NOTCURRENT is true. In
>> Andrew> the case above this means we will report the entry at index 9, which
>> Andrew> is for line 10, which is correct.
>>
>> Thanks for the explanation. It all made sense to me.
>>
>> Andrew> + if ![runto foo] {
>>
>> We're bracing if conditions these days.
>>
>> Otherwise this looks good to me.
>>
>> Approved-By: Tom Tromey <tom@tromey.com>
>
> I fixed the TCL bracing issue and pushed just this patch for now. I'm
> taking a deeper look at some of the questions you raised on the later
> patches.

Hi,

I'm getting:
...
$ pre-commit run --all-files
black....................................................................Passed
flake8...................................................................Passed
isort....................................................................Passed
codespell................................................................Passed
check-include-guards.....................................................Passed
check-gnu-style..........................................................Passed
- hook id: check-gnu-style
- duration: 0.19s
check-whitespace.........................................................Passed
pre-commit-setup.........................................................Passed
tclint...................................................................Failed
- hook id: tclint
- exit code: 1

gdb/testsuite/gdb.dwarf2/dw2-inline-bt.exp:211:26: expression with
substitutions should be enclosed by braces [unbraced-expr]
gdb/testsuite/gdb.dwarf2/dw2-inline-bt.exp:212:26: expression with
substitutions should be enclosed by braces [unbraced-expr]
...

Thanks,
- Tom