From: Trans Date: 2007-05-19T20:29:42+09:00 Subject: Re: Why not adopt "Python Style" indentation for Ruby? On May 19, 2:38 am, "Robert Dober" wrote: > On 5/18/07, Trans wrote: > > > > > On May 18, 5:22 pm, Sven Suska wrote: > > > Eric Mahurin schrieb: > > > > > You might consider something like this as an alternative block syntax. > > > > Maybe a ":" followed by a newline (and extra indentation) would start > > > > this style. I'm not sure of a clean way to handle arguments though. > > > > What about another syntax: > > > Putting a special character at the beginning of every line that is > > > governed by significant whitespace. > > > Thes would cause no problems with normal Ruby syntax, > > > but would provide a way to use significant indentation if one really > > > wants to. > > > > If "~" were that special character, it would look like that: > > > ~ 5.times do |n| > > > ~ n.times do > > > ~ print n > > > ~ puts > > > I can't count how many times I've forgotten "do". Sometimes I have > > wished a colon could "induce" the block: > > That puzzles me, would you not forget the ":" then? Or do you have a > lot of Python experience. Not that I think bad of the ":" syntax, just > wondering. Hehe. Probably so. I'm not a hisser ;) But I think I would forget the colon much less often, especially given it created indention significance. T.