[#114936] [Ruby master Feature#19908] Update to Unicode 15.1 — "nobu (Nobuyoshi Nakada) via ruby-core" <ruby-core@...>

Issue #19908 has been reported by nobu (Nobuyoshi Nakada).

24 messages 2023/10/02

[#115016] [Ruby master Bug#19921] TestYJIT#test_bug_19316 test failure — "vo.x (Vit Ondruch) via ruby-core" <ruby-core@...>

Issue #19921 has been reported by vo.x (Vit Ondruch).

21 messages 2023/10/12

[#115033] [Ruby master Misc#19925] DevMeeting-2023-11-07 — "mame (Yusuke Endoh) via ruby-core" <ruby-core@...>

Issue #19925 has been reported by mame (Yusuke Endoh).

12 messages 2023/10/13

[#115068] [Ruby master Bug#19929] Warnings for `mutex_m`, `drb` and `base64` appears while the gem spec has explicit dependencies — "yahonda (Yasuo Honda) via ruby-core" <ruby-core@...>

Issue #19929 has been reported by yahonda (Yasuo Honda).

8 messages 2023/10/17

[#115071] [Ruby master Misc#19931] to_int is not for implicit conversion? — "Dan0042 (Daniel DeLorme) via ruby-core" <ruby-core@...>

Issue #19931 has been reported by Dan0042 (Daniel DeLorme).

16 messages 2023/10/17

[#115139] [Ruby master Bug#19969] Regression of memory usage with Ruby 3.1 — "hsbt (Hiroshi SHIBATA) via ruby-core" <ruby-core@...>

Issue #19969 has been reported by hsbt (Hiroshi SHIBATA).

8 messages 2023/10/24

[#115165] [Ruby master Bug#19972] Install default/bundled gems into dedicated directories — "vo.x (Vit Ondruch) via ruby-core" <ruby-core@...>

Issue #19972 has been reported by vo.x (Vit Ondruch).

11 messages 2023/10/25

[#115196] [Ruby master Feature#19979] Allow methods to declare that they don't accept a block via `&nil` — "ufuk (Ufuk Kayserilioglu) via ruby-core" <ruby-core@...>

Issue #19979 has been reported by ufuk (Ufuk Kayserilioglu).

21 messages 2023/10/29

[ruby-core:115080] [Ruby master Bug#19231] Integer#step and Float::INFINITY - inconsistent behaviour when called with and without a block

From: "kyanagi (Kouhei Yanagita) via ruby-core" <ruby-core@...>
Date: 2023-10-18 07:10:25 UTC
List: ruby-core #115080
Issue #19231 has been updated by kyanagi (Kouhei Yanagita).


```
% docker run -it --rm rubylang/all-ruby env ALL_RUBY_SINCE=ruby-1.3 ./all-ruby -e 'inf = 1.0/0.0; 0.step(inf, 10) { |x| p x; break }'
ruby-1.3              /tmp/rbFgfjB4:1:in `/': divided by 0 (ZeroDivisionError)
                        from /tmp/rbFgfjB4:1
                  exit 1
ruby-1.3.1-990215     0
...
ruby-1.6.8            0
ruby-1.8.0            0.0
...
ruby-2.0.0-p648       0.0
ruby-2.1.0-preview1   0
...
ruby-3.3.0-preview2   0
```

The behavior seems to have changed in version 1.8.0 due to https://github.com/ruby/ruby/commit/936ad40.

The behavior seems to have changed in version 2.1.0 due to https://github.com/ruby/ruby/commit/fd4b5b8.
The issue is https://bugs.ruby-lang.org/issues/8838.

I think the behavior change in Ruby 1.8.0 was likely not intentional but rather accidental.

I couldn't find any documentation indicating that the behavior change in Ruby 2.1.0 was intentional.
There is no mention in NEWS-2.1.0 either.


----------------------------------------
Bug #19231: Integer#step and Float::INFINITY - inconsistent behaviour when called with and without a block
https://bugs.ruby-lang.org/issues/19231#change-104953

* Author: andrykonchin (Andrew Konchin)
* Status: Open
* Priority: Normal
* ruby -v: 3.1.2
* Backport: 2.7: UNKNOWN, 3.0: UNKNOWN, 3.1: UNKNOWN
----------------------------------------
The initial issue was reported here https://github.com/oracle/truffleruby/issues/2797.

`0.step(Float::INFINITY, 10)` returns:
- `Integers` when called with a block
- `Floats` when called without a block

I would expect `Floats` to be returned in both cases.

Examples:

```ruby
0.step(Float::INFINITY, 10).take(1).map(&:class)
=> [Float]
```

```ruby
0.step(Float::INFINITY, 10) { |offset| p offset.class; break }
# Integer
```

When `to` argument is a finite `Float` value then calling with a block returns `Floats` as well:

```ruby
0.step(100.0, 10) { |offset| p offset.class; break }
# Float
```

Wondering whether it's intentional behaviour.

I've found a related issue https://bugs.ruby-lang.org/issues/15518.



-- 
https://bugs.ruby-lang.org/
 ______________________________________________
 ruby-core mailing list -- ruby-core@ml.ruby-lang.org
 To unsubscribe send an email to ruby-core-leave@ml.ruby-lang.org
 ruby-core info -- https://ml.ruby-lang.org/mailman3/postorius/lists/ruby-core.ml.ruby-lang.org/

In This Thread