From: Dumaiu Date: 2006-07-26T23:50:16+09:00 Subject: Re: I'll have the duck! ara.t.howard@noaa.gov wrote: > > i was thinking about this on my ride home and recalled a term used in damian > conway's object oriented perl book (a fastastic book on oo programming btw.) > and a term he used way back then : 'interface polymorphism.' the more i > thought about it the more i like the term better than 'duck typing' because > it's closer in spirit to the idea of something being an acceptable object > merely by implimenting (via method_missing or whatever) a certain set of > behvaiours. > Holy cow; the whole thread was worth it just for this. This is on target: in ruby-talk 03608 matz in fact mentions as an illustration of 'implementation polymorphism' the Enumerable module, because the use of each() is the only requirement defined for compatibility. I will posit as a distinction that 'duck typing,' as we call it, is a description of an innate behavior of the language, while 'implementation inheritance' would be D. Conway's name for the general consequence of building projects with this kind of model in mind.