3 ms·
I gave an Intro to Ruby class the other day, and made a point of emphasizing the idea of message passing. I also gave a quick intro to `method_missing`. It pa
by jamesbritt 17y ago
I gave an Intro to Ruby class the other day, and made a point of emphasizing the idea of message passing. I also gave a quick intro to `method_missing`.
It pains me when people spend a fair amount of time coding Ruby, and then encounter metaprogamming and dynamic method invocation, and because of their wrong preconceptions they think it's deep, dark, super-genius hackery.
Unfortunately it gets clumsy to always say, "passes the message 'foo'" instead of "calls 'foo'", but if you can make the point early and toss in some reminders along the way the idea may stick.
- rit 17y agoWe live in a world where programmers think of Java's Object model when they think of OOP. Which is a crippled version of C++'s Object Model. About which Alan Kay said: 'Actually I made up the term "object-oriented", and I can tell you I did not have C++ in mind.' http://video.google.com/videoplay?docid=-2950949730059754521 http://video.google.com/videoplay?docid=-2950949730059754521