> >I personally do not use the term 'polymorphism' for the concept you > >proposed. But it is. Polymorphism is about dispatching (dynamically or statically). Whether it's on the receiver type or the arity / argument type is another matter. > But anyway I think the combination of it and optional > >argument (and variable number argument) increases program ambiguity. > >I'd like to avoid the pitfall C++ suffered. Any good idea? > Which pitfall? > In my experience, overloading based on the number of arguments > is usually not a good programming style, but overloading > based on the type of arguments often is. Regardless of whichever is the best (and of whether there is a best one), introducing that feature changes the basic set of assumptions of Ruby and requires the basic Object interface to be changed -- things like what is defining a method, changing one, removing one, finding one. Changing that makes Ruby no longer Ruby (granted that some LISPs and BASICs have greater divergences than that...) The change from (ANSI) C to C++ is different, because it does not so much break semantics, it mostly add new ones. Non-reflexive languages are easier to extend that way. matju