News for hackers. Stuff that matters.
Re:Perl 6 Optimism by emmelaich on Tuesday January 23, 2018 @10:24PM (#16220067)
When I started writing C a million years ago I thought to myself -- why the f$# does the compiler need to be told twice what the structure of my code is? Once with {} and once with indentation. It's not as if anyone half-sensible is going to write good code with bad indentation.

With that thought in mind, I am pathetically grateful for Python.

Re:Perl 6 Optimism by ptman on Wednesday January 24, 2018 @05:02AM (#16221574)
the compiler doesn't care about indentation, look at IOCCC https://www.ioccc.org
Re:Perl 6 Optimism by emmelaich on Wednesday January 24, 2018 @07:00AM (#16222039)
I know. I'm saying it should. Because why not?
Re:Perl 6 Optimism by newen on Wednesday January 24, 2018 @09:32AM (#16222937)
Because small invisible changes in the code text can result in actual changes in the logic of the code.
Re:Perl 6 Optimism by toyg on Wednesday January 24, 2018 @10:01AM (#16223154)
They are not invisible in any half-decent editor.
Re:Perl 6 Optimism by newen on Wednesday January 24, 2018 @10:22AM (#16223317)
But in the majority of editors that actual people use (mainly, jupyter/ipython), they are invisible. Not to distract from my point though, which is that a good programming language should be easily editable from Notepad.
Re:Perl 6 Optimism by toyg on Wednesday January 24, 2018 @10:21PM (#16228504)
This is where your bias shows. You define this "majority of people" by looking at your niche - you must be in academia or big data. I can tell you that in my niche nobody knows what the hell jupyter even is, and they use real editors like PyCharm, emacs, vim and so on, where whitespace is never a problem.

> a good programming language should be easily editable from Notepad.

The '90s called, they want their notepad back. Please. Not even Windows users run Notepad, anybody with a minimum of knowledge will use Notepad++. And guess what, N++ has plenty of features to deal with whitespace.

Re:Perl 6 Optimism by newen on Thursday January 25, 2018 @10:09AM (#16231232)
Yeah, point taken about my bias. Dealing with python via jupyter has been my biggest source of frustration with python.

But there are still plenty of cases where you will come across python via a bad interface, such as a shell interface to a server that I haven't set up properly (I come across this a lot since I've a lot of code running in clusters), and new computers or other people's bad setups or computers.

Even when using elpy-mode in Emacs, I've had problems when I tried to tabify and untabify a file (to change indentation length), which completely changed program logic in multiple places, and resulted in subtle bugs that I caught much later.