Hacker News new | past | comments | ask | show | jobs | submit login

I find this amusing because I've always found "lisp has too many parenthesis" and "python has too much significant whitespace" to be roughly equivalent in terms of relevance.



Nobody writes tools that randomly shred parentheses, but this happens all the time with whitespace. I'm halfway convinced Ruby is encroaching on Python because you can't really talk about the latter on the web without ridiculous workarounds.


How so? I suppose if you paste Python code in a comment box that happens to eat whitespace, then there is a problem, yes... but for those cases there's pastebin and such. Other than that, if you're writing a blog post or article, then you can just slap the Python code in <pre> blocks, which preserves the whitespace; most "humane" text editing formats like Textile and Markdown have ways to preserve it as well.


> comment box that happens to eat whitespace

In my experience, that's easily 2/3 of the web and half of all email and IM clients. It was so bad that I was surprised when it didn't fail somehow.

Pastebin is just the kind of workaround I would hate to be consigned to. Reading offline or printing becomes a huge headache because important details are constantly missing.


One thing that bothers me about Python's whitespace, is that it is not possible automatically indent Python code that has lost its indentation for some reason or another. You have to go back and read the original source to restore the meaning of the program even though you already have all the visible tokens it contains.




Consider applying for YC's W25 batch! Applications are open till Nov 12.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: