There are, by the way, other effects of the current default that are, even if minor, still annoying: ```ruby Enumerator.produce(1, &:succ).lazy.take(6).size # Ruby 3.4: => 6 -- which is correct and useful # Ruby 4.0: => nil -- ...zverok (Victor Shepelev)
> I think `Enumerator#size` should only be non-nil when it is known to be the exact size. > ... I would argue that it is _known_ to be infinite: that's how `produce` works: loops infinitely, unless explicitly stopped by an _exception_, t...zverok (Victor Shepelev)
In #21701 a new argument `size:` was introduced, and its default value is `nil` (unknown). While I support the new argument, I'd argue that the default should be `Float::INFINITY`. **Reasoning:** By _design_, `Enumerator.produce` ...zverok (Victor Shepelev)
* [Bug #21780] Change the default size of `Enumerator.produce` back to infinity (zverok) * While the new argument is a good addition to the API, I argue that `Float::INFINITY` would be a more friendly default, corresponding to the mos...zverok (Victor Shepelev)
Just noticed that on the latest `master` subclasses `#inspect` didn't change (unlike what @matz suggests here: https://bugs.ruby-lang.org/issues/21389#note-3): ```ruby class MySet < Set end p Set[1, 2, 3] #=> Set[1, 2, 3] p My...zverok (Victor Shepelev)
This works: ```ruby proc { |x| binding.eval('x') }.call(1) #=> 1 ``` This doesn't (neither with numbered parameters, nor with `it`): ```ruby proc { _1; binding.eval('_1') }.call(1) # undefined local variable or method '_1' for ...zverok (Victor Shepelev)
> I feel Unix command names are too short for usual programs. At the same time: * they are known at least to most of the console-using programmers, so this is a "dictionary" many of us familiar with * FileUtils have a practice of al...zverok (Victor Shepelev)
On the freshest `master`: ```ruby [1].each {_1; p binding.local_variable_defined?(:_1) } #=> true ``` It is inconsistent with changes in `#local_variables`/`#local_variable_get`/`#local_variable_set`. And inconsistent with handl...zverok (Victor Shepelev)