ruby/test
Matt Valentine-House 680e060026 [prism/compiler] end_cursor should never be NULL
This fixes a failed assertion reported to SimpleCov

https://github.com/simplecov-ruby/simplecov/issues/1113

This can be repro'd as follows:

1. Create a file `test.rb` containing the following code

```
@foo&.(@bar)
```

2. require it with branch coverage enabled

```
ruby -rcoverage -e "Coverage.start(branches: true); require_relative 'test.rb'"
```

The assertion is failing because the Prism compiler is incorrectly
detecting the start and end cursor position of the call site for the
implicit call .()

This patch replicates the parse.y behaviour of setting the default
end_cursor to be the final closing location of the call node.

This behaviour can be verified against `parse.y` by modifying the test
command as follows:

```
ruby --parser=parse.y -rcoverage -e "Coverage.start(branches: true); require_relative 'test.rb'"
```

[Bug #20866]
2024-11-21 13:51:59 +00:00
..
-ext- Move Array#map to Ruby 2024-11-13 12:27:26 -08:00
.excludes Use wide character startup 2024-11-05 23:04:49 +09:00
.excludes-parsey Remove no longer needed excludes files 2024-10-01 02:55:16 +09:00
benchmark [ruby/benchmark] Adjust ljust Benchmark#bm with labels was not using the highest length among the labels to adjust the correct ljust. Instead of printing the result during the report generation, now it is waiting to print the result once it is generated. 2024-11-08 11:32:30 +09:00
cgi
coverage [prism/compiler] end_cursor should never be NULL 2024-11-21 13:51:59 +00:00
date [ruby/date] Refine assertions 2024-11-05 04:19:39 +00:00
did_you_mean
digest
dtrace
erb
error_highlight [ruby/error_highlight] use `instance_method` to get method object 2024-10-31 00:30:10 +00:00
etc [ruby/etc] Fix sysconfdir when load-relative 2024-10-17 07:32:38 +00:00
fiber Introduce `Fiber::Scheduler#blocking_operation_wait`. (#12016) 2024-11-20 19:40:17 +13:00
fiddle [ruby/fiddle] Accept Symbol as Function name again 2024-11-11 09:19:48 +09:00
fileutils
io
irb [ruby/irb] Don't use delegator to install helper methods to main 2024-11-19 13:17:11 +00:00
json [ruby/json] Fix $VERBOSE restore 2024-11-11 15:13:24 -05:00
lib
logger [ruby/logger] Enable subclasses to configure level isolation 2024-11-07 00:17:16 +00:00
mkmf
monitor
net Do not wait connection attempt delay without in progress fds (#12087) 2024-11-15 00:25:59 +09:00
objspace ObjectSpace.dump: handle Module#set_temporary_name 2024-11-12 20:21:27 +01:00
open-uri
openssl asn1: fix ObjectId#== 2024-11-14 11:21:39 +09:00
optparse
ostruct
pathname Allow method chaining with Pathname#mkpath 2024-10-04 12:21:27 +09:00
prism [ruby/prism] Fix use of uninitialized value when parsing regexp 2024-11-12 14:19:46 +00:00
psych [ruby/psych] Eagerly require `date`. 2024-11-20 16:59:55 +00:00
rdoc [ruby/rdoc] Extract excerpt from raw pages correctly 2024-11-18 10:32:31 +00:00
reline [ruby/reline] Drop loading terminfo, remove fiddle dependency in 2024-11-14 23:14:18 +00:00
resolv test/resolv/test_dns.rb: Keep `UDPSocket`s until a free port is found 2024-10-10 14:44:51 +09:00
ripper [Bug #20784] Fix incomplete character syntax followed by EOF 2024-10-05 15:59:01 +09:00
ruby Fix a bug in rb_include_module that stops nested inclusion into module subclasses 2024-11-20 07:59:31 -08:00
rubygems [rubygems/rubygems] Add --attestation option to gem push 2024-11-20 19:32:49 +00:00
set
socket Disable HEv2 tests temporarily (#12097) 2024-11-15 18:12:37 +09:00
stringio [ruby/stringio] Copy from the relocated string 2024-11-05 05:01:03 +00:00
strscan [ruby/strscan] [JRuby] Optimize `scan()`: Remove duplicate `if 2024-10-26 18:44:15 +09:00
uri [ruby/uri] Removed duplicated declare step for constants under the URI::RFC2396_REGEXP::PATTERN 2024-11-14 02:20:04 +00:00
win32 [ruby/win32-registry] Fix compatibility with JRuby 2024-10-17 01:51:41 +00:00
win32ole
yaml [ruby/yaml] Make YAML::DBM optional 2024-10-16 17:04:37 +09:00
zlib [ruby/zlib] Don't call `rb_str_set_len` while released the GVL. 2024-11-20 21:02:16 +00:00
runner.rb
test_bundled_gems.rb Update test args with bundled gems. webrick has been removed that targets 2024-09-30 19:10:16 +09:00
test_delegate.rb
test_extlibs.rb
test_find.rb
test_forwardable.rb
test_ipaddr.rb [ruby/ipaddr] Added to_json/as_json method 2024-10-18 15:00:37 +00:00
test_open3.rb
test_pp.rb [ruby/pp] Fix pretty printing range begin/end with false or nil 2024-11-19 14:52:01 +00:00
test_prettyprint.rb
test_pstore.rb
test_pty.rb
test_rbconfig.rb
test_securerandom.rb
test_shellwords.rb
test_singleton.rb
test_tempfile.rb
test_time.rb
test_timeout.rb
test_tmpdir.rb
test_trick.rb
test_tsort.rb
test_unicode_normalize.rb
test_weakref.rb