This post originated from an RSS feed registered with Ruby Buzz
by Patrick Farley.
Original Post: Method Dispatch
Feed Title: Klank Boom Klang
Feed URL: http://klankboomklang.com/feed/
Feed Description: Ruby and otherwise by Patrick Farley
A good understanding of method dispatch can help in deciphering some of the odder corners of the Ruby object model. Luckily, method dispatch is not only straight forward, but entirely consistent for “normal” methods, singleton methods, and module methods.
In Matz’s Ruby Interpreter (MRI), method bodies are stored in a struct devoted to representing [...]