[#102393] [Ruby master Feature#17608] Compact and sum in one step — sawadatsuyoshi@...

Issue #17608 has been reported by sawa (Tsuyoshi Sawada).

13 messages 2021/02/04

[#102438] [Ruby master Bug#17619] if false foo=42; end creates a foo local variable set to nil — pkmuldoon@...

Issue #17619 has been reported by pkmuldoon (Phil Muldoon).

10 messages 2021/02/10

[#102631] [Ruby master Feature#17660] Expose information about which basic methods have been redefined — tenderlove@...

Issue #17660 has been reported by tenderlovemaking (Aaron Patterson).

9 messages 2021/02/27

[#102639] [Ruby master Misc#17662] The herdoc pattern used in tests does not syntax highlight correctly in many editors — eregontp@...

Issue #17662 has been reported by Eregon (Benoit Daloze).

13 messages 2021/02/27

[#102652] [Ruby master Bug#17664] Behavior of sockets changed in Ruby 3.0 to non-blocking — ciconia@...

Issue #17664 has been reported by ciconia (Sharon Rosner).

23 messages 2021/02/28

[ruby-core:102621] [Ruby master Bug#14094] IRB does not obey frame-level visibility modifiers

From: merch-redmine@...
Date: 2021-02-26 21:21:04 UTC
List: ruby-core #102621
Issue #14094 has been updated by jeremyevans0 (Jeremy Evans).

Status changed from Open to Closed

This was fixed in Ruby 3.0, with the change of the default irb context mode from 3 to 4.

----------------------------------------
Bug #14094: IRB does not obey frame-level visibility modifiers
https://bugs.ruby-lang.org/issues/14094#change-90614

* Author: headius (Charles Nutter)
* Status: Closed
* Priority: Normal
* ruby -v: 2.3.4
* Backport: 2.3: UNKNOWN, 2.4: UNKNOWN
----------------------------------------
I noticed the following today; IRB does not appear to obey the frame-local visibility modifiers like public and private:

```
$ irb
:here
irb(main):001:0> private
=> Object
irb(main):002:0> def foo; end; self.class.public_instance_methods.grep :foo
=> [:foo]
irb(main):003:0> private def foo; end; self.class.public_instance_methods.grep :foo
=> []
```

Note that the binding these commands are executed in is a method scope binding that *also* has its frame-local visibility set to private, so it seems like IRB is not working properly here.



-- 
https://bugs.ruby-lang.org/

Unsubscribe: <mailto:ruby-core-request@ruby-lang.org?subject=unsubscribe>
<http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-core>

In This Thread

Prev Next