| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
| |
except the special case `(nil..nil)`.
```
(1..).inspect #=> "1.."
(..5).inspect #=> "..5"
(nil..nil).inspect #=> "nil..nil"
```
[Bug #15745]
|
|
|
|
|
|
|
| |
The behavior of `Hash[[nil]] #=> {}` was a bug until 1.9.3, but had been
remained with a warning because some programs depended upon it.
Now, six years passed. We can remove the compatibility behavior.
[Bug #7300]
|
| |
|
|
|
|
|
|
| |
on initialize
This fixes https://github.com/ruby/ruby/pull/2188
|
| |
|
| |
|
| |
|
|
|
|
| |
[Bug #15821]
|
| |
|
| |
|
| |
|
|
|
|
|
| |
I'm debugging [Bug #15821] but my patch introduces another issue.
So I simply skip this test and re-enable it later.
|
| |
|
| |
|
|
|
|
|
|
| |
The namespace "Readline" doesn't exist when running tests if readline.so
doesn't exist and Reline exists. So test classes shouldn't be at nested
namespaces under "Readline".
|
|
|
|
|
| |
Now, GC.compact has issues which makes rubyci RED, so I skip this test
and debug soon.
|
|
|
|
|
|
|
| |
Examples why ASCII-only optimization cannot apply multi-byte
encodings which have 7-bit trailing bytes.
Suggested by @duerst at https://github.com/ruby/ruby/pull/2187#issuecomment-492949218
|
|
|
|
| |
merged https://github.com/rubygems/rubygems/pull/2765
|
|
|
|
| |
[Bug #15850]
|
|
|
|
|
|
|
|
| |
This commit adds an alternative packing strategy for compaction.
Instead of packing towards "most pinned" pages, we can pack towards
"most empty" pages. The idea is that we can double the heap size, then
pack all objects towards the empty side of the heap. This will ensure
maximum chaos for testing / verification.
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
| |
Aliasing a method preserves its visibility. These aliases turn
formerly-public methods into private. Should make them public
again. [Bug #15847]
|
|
|
|
|
|
|
|
|
| |
Instead, look for instance methods of Kernel.
Otherwise, instance methods of Module (which are methods of Kernel
itself) are mistakenly believed to exist, and it fails when calling
Kernel.instance_method().
Closes: https://github.com/ruby/ruby/pull/1422
|
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
This reverts commit b1767e56b158d8307412a0928a7ac2366541429d.
|
| |
|
| |
|
|
|
|
|
| |
to fix
https://ci.appveyor.com/project/ruby/ruby/builds/24438615/job/yld1utsltxag9dr2
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is a follow up for 3f9562015e651735bfc2fdd14e8f6963b673e22a.
Before this commit, it was possible to create a shared string which
shares with another shared string by passing a frozen shared string
to `str_duplicate`.
Such string looks like:
```
-------- -----------------
| root | ------ owns -----> | root's buffer |
-------- -----------------
^ ^ ^
----------- | |
| shared1 | ------ references ----- |
----------- |
^ |
----------- |
| shared2 | ------ references ---------
-----------
```
This is bad news because `rb_fstring(shared2)` can make `shared1`
independent, which severs the reference from `shared1` to `root`:
```c
/* from fstr_update_callback() */
str = str_new_frozen(rb_cString, shared2); /* can return shared1 */
if (STR_SHARED_P(str)) { /* shared1 is also a shared string */
str_make_independent(str); /* no frozen check */
}
```
If `shared1` was the only reference to `root`, then `root` can be
reclaimed by the GC, leaving `shared2` in a corrupted state:
```
----------- --------------------
| shared1 | -------- owns --------> | shared1's buffer |
----------- --------------------
^
|
----------- -------------------------
| shared2 | ------ references ----> | root's buffer (freed) |
----------- -------------------------
```
Here is a reproduction script for the situation this commit fixes.
```ruby
a = ('a' * 24).strip.freeze.strip
-a
p a
4.times { GC.start }
p a
```
- string.c (str_duplicate): always share with the root string when
the original is a shared string.
- test_rb_str_dup.rb: specifically test `rb_str_dup` to make
sure it does not try to share with a shared string.
[Bug #15792]
Closes: https://github.com/ruby/ruby/pull/2159
|
| |
|
|
|
|
|
|
| |
to prevent failure like
https://app.wercker.com/ruby/ruby/runs/mjit-test1/5cd28aa6ab79a30008ee819b?step=5cd28b2403f44600070db083
with --jit-verbose=1.
|
|
|
|
| |
[Bug #15780]
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This allows cases such as:
```ruby
m ->(a = ->{@1}) {a}
m.call.call(1)
m2 ->(a: ->{@1}) {a}
m2.call.call(2)
```
Previously, this would cause a syntax error.
[Bug#15789]
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Because `proc{|| @1}` is a syntax error, the following should
also be syntax errors:
```ruby
proc { |
| @1}
```
```ruby
proc { |; a| @1 }
```
This fixes both cases.
[Bug #15825]
|
|
|
|
|
| |
* parse.y (case_args): moved "duplicated when clause" warning from
compile phase, so that `ruby -wc` shows them.
|
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
Closes: https://github.com/ruby/ruby/pull/2163
|
| |
|
|
|
|
|
| |
The debug option of IRB is deleted because it's just for IRB's pure Ruby
parser.
|
| |
|
| |
|