From: Eleanor McHugh Date: 2009-06-04T06:15:03+09:00 Subject: Re: Pythonic indentation (or: beating a dead horse) On 3 Jun 2009, at 17:30, Marc Heiler wrote: > What does "meta-programming" NEED to have to do anything > with indent at all? Because if indentation becomes significant it's important that it doesn't break any central feature of Ruby, and my gut feeling (which I concede may be totally misguided) is that the area where such breakage is most likely to occur will be meta-programming. So whilst it may not have anything to do with the matter at all, determining whether or not that is the case is still an important consideration. At least for me. > Last but not least, the ultimate freedom would be to have the ability > to omit end as an optional feature in ruby available with a default > being the way it currently is. I'm not sure that is such an ultimate freedom, but if it is remember that all freedom comes with responsibility. In this case ensuring code consistency. > To switch between indents, one could use #comment marks, like it is > done for the Encoding stuff already (or for vim files etc...) Making two distinct structural layouts interchangeable in a single codebase would make them marginally less readable than sticking to one or other convention. And as maintenance of code is often orders of magnitude more expensive than development that difference of readability equates to a real long-term cost. > Enforcement about official ruby stdlib could still follow one specific > guideline - i.e. it must be properly documented and tested, and it > must > use "official" useage of end. (This would be an enforcement of a > policy, > rather than syntax.) The stdlib is as close to a definition of Ruby idiom as we have, so if significant indentation isn't going to be allowed there it follows that significant indentation will not become idiomatic and will instead be idiosyncratic. If that's the case, then what problem is it solving? Ellie Eleanor McHugh Games With Brains http://slides.games-with-brains.net ---- raise ArgumentError unless @reality.responds_to? :reason