This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH] sigall.exp and friends: centralize signals list.
On 07/19/2012 08:16 PM, Tom Tromey wrote:
>>>>>> "Pedro" == Pedro Alves <palves@redhat.com> writes:
>
> Pedro> - We really want to skip the first signal, because that's
> Pedro> handled before the loop. It doesn't matter which signal it is.
> Pedro> So I concluded that not hard coding a signal name was a little
> Pedro> better, and went with a for with index, which expresses the idea
> Pedro> naturally.
>
> Alternatively you can use [lrange $signals 1 end]
Or even:
for {set i 1} {$i < [llength $signals]} {incr i} {
which in hindsight, I have no idea why I didn't do it like that, over a
silly "if i==0 continue". :-P
I'll use lrange.
--
Pedro Alves