diff options
author | nagachika <nagachika@ruby-lang.org> | 2022-11-13 11:22:53 +0900 |
---|---|---|
committer | nagachika <nagachika@ruby-lang.org> | 2022-11-13 11:22:53 +0900 |
commit | f8044a770009b78d46b583600c9bd6660328303f (patch) | |
tree | dcf66bb83f456fe315b4b082dc656badab5dc99b /bootstraptest | |
parent | 728d9f18348bcffedb0880c67015f08a7c19665f (diff) |
merge revision(s) 131c31a9209c61f84d318aa18b61f468f48b8219: [Backport #19081]
[Bug #19081] Show the caller location in warning for Ractor
The internal location in ractor.rb is not usefull at all.
```
$ ruby -e 'Ractor.new {}'
<internal:ractor>:267: warning: Ractor is experimental, ...
```
---
bootstraptest/test_ractor.rb | 6 ++++++
ractor.c | 6 ------
ractor.rb | 4 ++++
3 files changed, 10 insertions(+), 6 deletions(-)
Diffstat (limited to 'bootstraptest')
-rw-r--r-- | bootstraptest/test_ractor.rb | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/bootstraptest/test_ractor.rb b/bootstraptest/test_ractor.rb index b29db7ab0e..95c4a39ab4 100644 --- a/bootstraptest/test_ractor.rb +++ b/bootstraptest/test_ractor.rb @@ -1579,4 +1579,10 @@ assert_equal "ok", %q{ end } +assert_match /\Atest_ractor\.rb:1:\s+warning:\s+Ractor is experimental/, %q{ + Warning[:experimental] = $VERBOSE = true + STDERR.reopen(STDOUT) + eval("Ractor.new{}.take", nil, "test_ractor.rb", 1) +} + end # if !ENV['GITHUB_WORKFLOW'] |