MonkeeSage wrote:
> I trust everything that Wikipedia says.
(Well, I paraphrased that a bit...)
You, there's a way of thinking about the phrase "duck typing" that'll
help explain that it's really a description of a programming strategy.*
Intepret "duck" as a verb. When you use "duck typing," as a programmer,
you "duck" the programming language's definition of "typing." (Class, in
Ruby's case) Wait, that sounds familiar... did I read that somewhere?
Just a thought.
Devin
(I was kidding, Jordan. Just messing wit j00. I lack knowledge of
category theory.)
* Scanning over chapter 23 of the PickAxe seems to confirm that that was
the intention -- pages 370-1 use the phrases "duck typing philosophy"
and "this style of laissez-faire programming," though, granted, the book
isn't consistent. Hey, the phrase is out there. It doesn't seem to have
a canonical definition. It's an ad hoc term. Treat it as such, I say.