Commit graph

16449 commits

Author SHA1 Message Date
Nobuyoshi Nakada
c0a2d95cf3 Update rb_ractor_ensure_shareable
* Fixed use of rb_ractor_shareable_p
* Raise Ractor::IsolationError
2020-12-23 13:50:42 +09:00
Nobuyoshi Nakada
b2aa21b868 Split the test 2020-12-23 13:50:42 +09:00
Nobuyoshi Nakada
d1c7db9d00 Added assertions 2020-12-23 13:50:42 +09:00
Nobuyoshi Nakada
e70206f570 Added dedicated helper methods 2020-12-23 13:50:42 +09:00
Nobuyoshi Nakada
7a094146e6 Changed shareable literal semantics [Feature #17397]
When `literal`, check if the literal about to be assigned to a
constant is ractor-shareable, otherwise raise `Ractor::Error` at
runtime instead of `SyntaxError`.
2020-12-23 13:50:42 +09:00
Hiroshi SHIBATA
339227363c Merge RubyGems 3.2.3 and Bundler 2.2.3 2020-12-23 10:17:41 +09:00
Nobuyoshi Nakada
733ed1e184 ripper: fix bad label parameter handling [Bug #17425] 2020-12-23 09:56:35 +09:00
Marc-Andre Lafortune
cd63f0358f [ruby/etc] Make Ractor safe 2020-12-22 19:46:07 -05:00
Kenta Murata
74652e640a
[memory_view][fiddle] Rename len to byte_size in rb_memory_view_t 2020-12-23 09:24:53 +09:00
aycabta
841d22ea47 [ruby/reline] [ruby/irb] Handle multiple newlines in a token correctly
Co-authored-by: manga_osyo <manga.osyo@gmail.com>
Co-authored-by: ima1zumi <mariimaizumi5@gmail.com>

c59a9be82f

a7922da16b
2020-12-23 06:06:07 +09:00
Delton Ding
f1591b3858 Add verbose nil in testing 2020-12-23 03:27:14 +09:00
Delton Ding
c6d7e02b90 Enable Fiber.current and Fiber#alive? call inside ractor 2020-12-23 03:27:14 +09:00
Kazuki Tsujimoto
31b17a14ab
Make NoMatchingPatternError a subclass of StandardError 2020-12-23 02:31:02 +09:00
ima1zumi
299f5708a2 [ruby/reline] Fixed an exception occurred when ambiguous width character was passed to #calculate_width [Bug #17405]
f79b4c857f
2020-12-22 23:45:43 +09:00
aycabta
b52bc4a9c2 [ruby/reline] Support isearch-terminators
a7922da16b
2020-12-22 23:45:43 +09:00
aycabta
294552ca6c [ruby/reline] Render refreshed prompt just after i-search finished
0d3188fe34
2020-12-22 23:45:43 +09:00
Akinori MUSHA
96b8816793 Import set 1.0.1
- Eliminate warnings
- Convert rdoc to markdown
2020-12-22 21:41:44 +09:00
Hiroshi SHIBATA
edb76e8765 Prepare to release json-2.5.0 2020-12-22 19:44:27 +09:00
Marc-Andre Lafortune
f2f00e24fa [ruby/date] Make Ractor-compatible 2020-12-22 03:12:51 -05:00
卜部昌平
fa356a798a Enumerator.new: raise unless block given
Has been deprecated since c73b6bd7eb.
[Feature #17116] [ruby-dev:50945]
2020-12-22 13:52:03 +09:00
Akinori MUSHA
3fa4bd8292 Import set 1.0.0
- SortedSet has been removed for dependency and performance reasons.
- Set#join is added as a shorthand for `.to_a.join`.
- Set#<=> is added.

https://github.com/ruby/set/blob/v1.0.0/CHANGELOG.md
2020-12-22 12:20:21 +09:00
Koichi Sasada
520dcbd600 reset cache before iterating
cee02d754d resets pCMC and `me`
will be a invalidated and continuing the invalidated `me`,
it will break the data structure. This patch tris to clear
all methods of specified class before manipulating the `me`s.
[Issue #17417]
2020-12-22 06:09:30 +09:00
Kenta Murata
14d7d1df25
[json] Make json Ractor safe 2020-12-21 22:10:43 +09:00
Kenta Murata
98cc15ed1e
[json] Stop using prototype objects 2020-12-21 22:10:33 +09:00
Nobuyoshi Nakada
d84dd66da0
Fixed a typo in an error class name 2020-12-21 18:17:45 +09:00
Hiroshi SHIBATA
391343e828 [ruby/rdoc] Guard for WEBrick
b1e7129e05
2020-12-21 16:21:46 +09:00
Nobuyoshi Nakada
8680ae9cbd
irb: Removed unused variables 2020-12-20 19:36:24 +09:00
Nobuyoshi Nakada
5b98b2ce39 win32: Use UTF-8 as filesystem encoding [Feature #12654]
Co-Authored-By: Dāvis Mosāns <davispuh@gmail.com>
2020-12-20 18:34:04 +09:00
Nobuyoshi Nakada
feea436feb
irb: Define extension command only on the given object
Not to interfer in class variables.
2020-12-20 18:26:38 +09:00
Nobuyoshi Nakada
0fad9a9e30
Set non-verbose mode as well as tty mode 2020-12-20 17:15:02 +09:00
aycabta
59b84fbf2e Set :DEFAULT to PROMPT_MODE for CI 2020-12-20 17:07:24 +09:00
aycabta
216a087e93 Suppress errors related to using variables that are not directly related to testing 2020-12-20 16:48:47 +09:00
aycabta
9f08e3c703 [ruby/irb] Add measure command
You can use "measure" command to check performance in IRB like below:

  irb(main):001:0> 3
  => 3
  irb(main):002:0> measure
  TIME is added.
  => nil
  irb(main):003:0> 3
  processing time: 0.000058s
  => 3
  irb(main):004:0> measure :off
  => nil
  irb(main):005:0> 3
  => 3

You can set "measure :on" by "IRB.conf[:MEASURE] = true" in .irbrc, and, also,
set custom performance check method:

  IRB.conf[:MEASURE_PROC][:CUSTOM] = proc { |context, code, line_no, &block|
    time = Time.now
    result = block.()
    now = Time.now
    puts 'custom processing time: %fs' % (Time.now - time) if IRB.conf[:MEASURE]
    result
  }

3899eaf2e2
2020-12-20 16:23:59 +09:00
Marc-Andre Lafortune
6343a81129 [ruby/ostruct] Add Ractor test 2020-12-19 17:13:08 -05:00
Marc-Andre Lafortune
67e062b523 [ruby/matrix] Add Ractor test
This reverts commit cacdf2681d.
2020-12-19 17:13:08 -05:00
Kenta Murata
de80b92891
[pathname] Make Pathname Ractor safe (#3940) 2020-12-20 00:40:47 +09:00
Kenta Murata
8355a3e17b
[bigdecimal] Fix deprecation warning test 2020-12-19 22:13:59 +09:00
Kenta Murata
df3deb3baa
[bigdecimal] Add BigDecimal#n_significant_digits
981dc48f95
9ecf880ec0
2020-12-19 22:13:59 +09:00
Kenta Murata
654f6fbf19
[bigdecimal] Make BigDecimal#precs deprecated
7e80e6e145
0ed7846e8c
2020-12-19 22:13:58 +09:00
Kenta Murata
ff9e40811c
[bigdecimal] Add BigDecimal#precision
458eb66c49
2020-12-19 22:13:58 +09:00
Kenta Murata
928a06723d
[bigdecimal] Make bigdecimal Ractor safe
93fc392640
a90d13c4d0
2020-12-19 22:13:57 +09:00
Kenta Murata
e1424c3501
[bigdecimal] Fix the default precision of Float#to_d
Fix https://github.com/ruby/bigdecimal/issues/70
[Bug #13331]

aa536cd4b5
2020-12-19 22:13:53 +09:00
Yusuke Endoh
4735a5b9d2 test/ruby/test_module.rb: Avoid "warning: method redefined" 2020-12-19 21:19:16 +09:00
Yusuke Endoh
1ba8d63b49 Recommit 34f0606217 2020-12-19 18:22:44 +09:00
Nobuhiro IMAI
e33eb09b76 ripper: fix #tok on some error events [Bug 17345]
sorting alias target by event arity, and setup suitable `Elem` for error.
2020-12-19 17:32:39 +09:00
Hiroshi SHIBATA
349e79bae0
Try to test with rake-13.0.2 again.
[ruby/fileutils] Make verbose output go to stdout instead of stderr

  This reverts commit 510df47f5f.
2020-12-19 16:53:18 +09:00
Kenta Murata
b66f52b0e3
[digest] Make digest Ractor safe
c13a024b85
9edca3f8be
378b56b6ca
2020-12-19 15:08:01 +09:00
Yusuke Endoh
5b2cf7eac8 Partially reintroduce e042e8460b and ...
34f0606217

Add a test for alias_method
2020-12-19 12:24:41 +09:00
Nobuyoshi Nakada
5616f2ee93
Added missing tests for public, private, protected and alias_method 2020-12-19 11:39:03 +09:00
Koichi Sasada
cee02d754d fix refinements/prepend bug
replaced method entry should be invalidated.
[Bug #17386]
2020-12-19 04:33:04 +09:00