Ruby’s self keyword is one of those things that makes no sense until it does. Even experienced Rubyists sometimes forget its more obscure uses. Here are a few examples: To access instance methods from a mixin: self.name To create class methods: def self.my_method To access the metaclass: class << self They look arbitrary, like facts to be memorized. But there is an underlying structure. When you u
