From: Martin DeMello Date: 2004-07-03T21:52:50+09:00 Subject: Re: ruby-dev summary 23763-23840 Minero Aoki wrote: > > + There are similar methods such as Integer(), String(), etc. > - URI.[] is better because URI() pollutes the global name space. > - String(obj) calls obj.to_s. Integer(obj) calls obj.to_i. > But URI(obj) does not call obj.to_uri. > (Note that Complex(obj) does not call obj.to_complex, too.) > - A method name which begins with a capital looks bad. I like the idea of Class() being used as a constructor - it's a neat, readable idiom. I don't really see this as namespace pollution, since the class and the method are in some sense logically bound together; similarly the fact that this is a special case makes the capital acceptabe. martin