From: waheed.barghouthi@... Date: 2019-04-07T14:56:29+00:00 Subject: [ruby-core:92178] [Ruby trunk Feature#15743] RubyVM should be renamed to CRuby Issue #15743 has been updated by waheedi (Waheed Barghouthi). Eregon (Benoit Daloze) wrote: > waheedi (Waheed Barghouthi) wrote: > > @Eregon, I do believe there is a sense in what you are trying to do, but what makes more sense to me is that Matz Ruby was named "Ruby". > > I believe "Ruby" refers to the programming language and from that "Ruby VM" is logically *a* "Virtual Machine executing Ruby code". > There is more than one VM that can execute Ruby code, so I think "the Ruby VM" is simply confusing. > Please see my comment about `ruby` vs `Ruby` above too. > > > You can still clear out the confusion without prepending any letters to Ruby > > I'm not prepending letters, it's what matz himself would call this implementation AFAIK. Here is a blog post explaining it: > http://engineering.appfolio.com/appfolio-engineering/2017/12/28/cruby-mri-jruby-rubyspec-rubinius-yarv-a-little-bit-of-ruby-naming > > BTW, that blog post makes a good point: > "Ruby 1.8, YARV and MJIT are all CRuby, but they're different generations of tech within CRuby: the old Ruby 1.8 interpreter, then YARV, then MJIT." > > > I believe adding a note like the ones you added "This class is MRI specific as it exposes implementation details" would be sufficient to resolve any confusion. > > I think that can be made clear enough in the documentation (if people read it), but it's not clear in the calling code. > So people reading the code would still not be clear about whether that code uses MRI-specific features. > And I would guess many people won't notice the change in documentation of RubyVM. > > FWIW, Bundler mentions multiple times in man pages "Ruby VM" and "the running Ruby VM" which means "a Ruby implementation VM", so that's clearly another take on what "Ruby VM" means. I totally agree on your point > There is more than one VM that can execute Ruby code, so I think "the Ruby VM" is simply confusing. The pull request you just created does not really reflect what you are saying, `The RubyVM module only exists on MRI. +RubyVM+ is not defined in` Even if Matz refer to Ruby as CRuby that does not mean he would like to rename it, but i think that to clarify that he is referring to the C Ruby implementation. I definitely can see the confusion caused by calling it RubyVM but there were no other implementations when it started, and it made total sense at the time, and I believe changing it would not really help more than 2% of the Ruby enthusiasts and they already know about it by now :) Have a good day ---------------------------------------- Feature #15743: RubyVM should be renamed to CRuby https://bugs.ruby-lang.org/issues/15743#change-77507 * Author: Eregon (Benoit Daloze) * Status: Open * Priority: Normal * Assignee: * Target version: Next Major ---------------------------------------- My understanding is that `RubyVM` is supposed to only exist on MRI/CRuby, and not on any other Ruby implementation. In fact, almost all features under `RubyVM` are not realistically implementable on other major Ruby implementations (JRuby, TruffleRuby, Rubinius). Unfortunately, the name doesn't reflect that it is specific to CRuby, e.g., JRuby/TruffleRuby/Rubinius are also "Ruby VMs". And as a result it is not clear for many Ruby users that RubyVM is CRuby-specific. The documentation is also unclear: ``` The RubyVM module provides some access to Ruby internals. This module is for very limited purposes, such as debugging, prototyping, and research. Normal users must not use it. ``` So I propose to rename RubyVM to CRuby. That way, it is clear for everyone that this module is CRuby-specific. It's also consistent with the JRuby module, the TruffleRuby module and the Rubinius module. Proposed migration path: * Introduce CRuby as an alias of RubyVM on `trunk`, and deprecate the RubyVM constant on `trunk` (for 2.7). * Remove `RubyVM` in Ruby 3.0. What do you think? cc @ko1 @k0kubun @headius -- https://bugs.ruby-lang.org/ Unsubscribe: