From: Dave Thomas Date: 2001-06-16T08:59:35+09:00 Subject: [ruby-talk:16513] Re: Playing with Ruby Syntax (was: Initial thoughts about Ruby From a Smalltalk Programmer) Mathieu Bouchard writes: > If I know how those keyword arguments actually work (vaguely like > "=>" hash passing, plus checking on the names of the keys), then the > problem might be that it's too close to a hash parameter to be truly > smalltalkish. the defining feature of calling syntax in smalltalk > is that it's the actual sequence of keywords that you are using that > *are* the selector. method. The keyword-arg feature does not select > which method is called, which means that you have to write that > separately. Agreed: they won't help in method dispatch. However, adding keyword arguments to the call will allow the parser to be cleverer. Say the syntax is method arg1: arg2: then we could have automatic conversion of blocks to procs when they appear after an argument name. This would let us write Smalltalk-ish things such as my_if a = b then: { puts "one"} else: { puts "two" } I can't see the harm in this, and feel it would make some things easier to write. Others seem to dislike the idea. It would be interesting to discuss it. Dave