From: sawadatsuyoshi@... Date: 2014-08-29T14:02:05+00:00 Subject: [ruby-core:64655] [ruby-trunk - Feature #10183] An alternative name for method `class` Issue #10183 has been updated by Tsuyoshi Sawada. Thomas Sawyer wrote: > I once suggested `object_class` to go along with `object_id`. > > Also, see https://bugs.ruby-lang.org/issues/6478 which talks about `BasicObject#__class__`. What is `__class__`? ---------------------------------------- Feature #10183: An alternative name for method `class` https://bugs.ruby-lang.org/issues/10183#change-48555 * Author: Tsuyoshi Sawada * Status: Open * Priority: Normal * Assignee: * Category: * Target version: ---------------------------------------- The method `class` is special in that it always has to have an explicit receiver in order to avoid crash with the keyword `class`. But this is very inconvenient. I have seen so many self.class in codes. I propose that there should be an alternative name for this method so that it can be used with an implicit receiver, and the method name `class` should be gradually depricated. As for the name, I have no clear idea. I can only think of `klass`, but perhaps someone else might come up with a better name. -- https://bugs.ruby-lang.org/