Re: [PATCHv2] Restore gdb.SYMBOL_STRUCT_DOMAIN constant

Tom de Vries
2021-06-05T22:36:47Z

On 6/5/21 3:57 PM, Tom Tromey wrote:
>>>>>> "Hannes" == Hannes Domani <ssbssa@yahoo.de> writes:
>
> Hannes> Sorry about that.
> Hannes> I'm gonna push the below as obvious.
>
> Thank you. It's an easy error to make :)
>

Indeed, it is :)

Maybe easy enough to warn about in gdb_test_multiple:
...
if { [regexp -line {python print +[^(]} $command] } {
warning [concat \
"Missing parentheses in python print command," \
" will fail with python3"]
}
...
?

Or, even correct automatically:
...

if { [regexp -line {python print +[^(]} $command] } {
set command [regsub {python print (.*)} $command \
{python print (\1)}]
}
...
?

Thanks,
- Tom