[#120465] [Ruby master Bug#20998] rb_str_locktmp() changes flags of frozen strings and string literals — "Eregon (Benoit Daloze) via ruby-core" <ruby-core@...>
Issue #20998 has been reported by Eregon (Benoit Daloze).
17 messages
2025/01/03
[ruby-core:120808] [Ruby master Bug#21094] Module#set_temporary_name does not affect a name of a nested module
From:
"andrykonchin (Andrew Konchin) via ruby-core" <ruby-core@...>
Date:
2025-01-28 11:19:20 UTC
List:
ruby-core #120808
Issue #21094 has been reported by andrykonchin (Andrew Konchin).
----------------------------------------
Bug #21094: Module#set_temporary_name does not affect a name of a nested module
https://bugs.ruby-lang.org/issues/21094
* Author: andrykonchin (Andrew Konchin)
* Status: Open
* ruby -v: 3.4.1
* Backport: 3.1: UNKNOWN, 3.2: UNKNOWN, 3.3: UNKNOWN, 3.4: UNKNOWN
----------------------------------------
Wondering whether it's intentional and correct behaviour:
```ruby
m = Module.new
m::N = Module.new
p m::N.name # => "#<Module:0x000000010d0a00b0>::N"
m.set_temporary_name("foo")
p m::N.name # => "#<Module:0x000000010d0a00b0>::N"
```
I would expect that setting `foo` as a temporary name changes `m::N.name` to `foo::N`.
--
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/lists/ruby-core.ml.ruby-lang.org/