This is the mail archive of the guile@cygnus.com mailing list for the Guile project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Reader option to permit brackets as parentheses


Telford Tendys wrote:
> 
> > Is that what python is? Sounds like a _very_ bad idea to 
> > have code
> > meaning depending on whitespace.
> 
> Why? Whitespace is understandable, obvious, easy to edit, 
> easy to align. 

While I'm not aware of exactly what rules Python uses, I would imagine:

* The meaning of code could depend on what tab-spacing your editor uses.
I use tab spacing 4 and the code does X. You use tab spacing 8 so you
think the code does Y. Admittedly this may not often cause a problem,
but when it does - YOW! It could bring down your countries
telecommunications network (if they used python, which they wouldn't).

* With some cleverness you could probably fiddle with tabs and spaces to
maliciously make code do something different than you think.

* If you have to read some code written by someone with different tab
spacings at least it's possible to understand what's going on in other
languages, even if difficult.

* When you cut and paste code with various tools, most of them lose tab
spacing or otherwise screw up the white-space. With most languages, no
problem. You paste it into emacs and it fixes it all up for you.

> I think that people had this big reaction 
> against whitespace when they saw Pascal and C as the next 
> big thing that would replace FORTRAN and they wanted to 
> show that they were cool by allowing whitespace to be 
> anywhere at all. Since then all they have done is argue 
> over indentation and pretty printing standards...

I guess that's because there are so many options available. At least
with scheme there aren't really many options - only the aesthetic
decision on where to break lines.

> This implies that these characters cannot be used in 
> normal identifiers (a good idea anyhow for general sanity)

I don't think it's a good idea unless there really is some future use in
mind. It might be nice to have identifiers called my{car} or my{house}.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]