mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
.gdbinit (print_lineno): follow up changes in r61534, r61536
insns_info was refactored. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61700 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
1e395da1f5
commit
580424d533
1 changed files with 6 additions and 5 deletions
11
.gdbinit
11
.gdbinit
|
@ -1022,19 +1022,20 @@ define print_lineno
|
|||
end
|
||||
|
||||
set $i = 0
|
||||
set $size = $iseq->body->insns_info_size
|
||||
set $table = $iseq->body->insns_info
|
||||
set $size = $iseq->body->insns_info.size
|
||||
set $table = $iseq->body->insns_info.body
|
||||
set $positions = $iseq->body->insns_info.positions
|
||||
#printf "size: %d\n", $size
|
||||
if $size == 0
|
||||
else
|
||||
set $i = 1
|
||||
while $i < $size
|
||||
#printf "table[%d]: position: %d, line: %d, pos: %d\n", $i, $table[$i].position, $table[$i].line_no, $pos
|
||||
if $table[$i].position > $pos
|
||||
#printf "table[%d]: position: %d, line: %d, pos: %d\n", $i, $positions[$i], $table[$i].line_no, $pos
|
||||
if $positions[$i] > $pos
|
||||
loop_break
|
||||
end
|
||||
set $i = $i + 1
|
||||
if $table[$i].position == $pos
|
||||
if $positions[$i] == $pos
|
||||
loop_break
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue