Actions
Bug #21259
closed
The Prism compiler wrongly creates a line number of zero
Description
test.rb
TracePoint.new(:line) do |tp|
p tp
end.enable
load "./target.rb"
target.rb
if true..true
end
$ ~/work/ruby/local/bin/ruby --parser=prism test.rb
#<TracePoint:line test.rb:5>
#<TracePoint:line /tmp/reproduce-simplecov-ruby34-bug/target.rb:0> # <=== This lineno should be 1
$ ~/work/ruby/local/bin/ruby --parser=parse.y test.rb
#<TracePoint:line test.rb:5>
#<TracePoint:line /tmp/reproduce-simplecov-ruby34-bug/target.rb:1>
Updated by mame (Yusuke Endoh) 4 months ago
- Related to Bug #21220: Memory corruption in update_line_coverage() [write at index -1] added
Updated by tenderlovemaking (Aaron Patterson) 13 days ago
- Status changed from Assigned to Closed
- Backport changed from 3.2: UNKNOWN, 3.3: UNKNOWN, 3.4: UNKNOWN to 3.2: UNKNOWN, 3.3: UNKNOWN, 3.4: REQUIRED
Fixed in 148db9c80f11af1780f0f3685201f28de8f6b47a
Updated by k0kubun (Takashi Kokubun) 9 days ago
- Backport changed from 3.2: UNKNOWN, 3.3: UNKNOWN, 3.4: REQUIRED to 3.2: UNKNOWN, 3.3: UNKNOWN, 3.4: DONE
ruby_3_4 8b505a286080fead52a603fcd2761c2d6b3e3aec merged revision(s) [ruby-core:121605]" href="/projects/ruby-master/repository/git/revisions/148db9c80f11af1780f0f3685201f28de8f6b47a">148db9c80f11af1780f0f3685201f28de8f6b47a.
Actions
Like0
Like0Like0Like0