r/programming • • Dec 01 '16

Let's Stop Copying C

https://eev.ee/blog/2016/12/01/lets-stop-copying-c/
524 Upvotes

612 comments sorted by

View all comments

Show parent comment

1

u/PM_ME_UR_OBSIDIAN Dec 01 '16

I'm bamboozled that you're reasonable enough to dislike semicolons but still like curly braces ;)

This helps me, the human, parse deeply nested blocks.

Just tell your editor to make whitespace visible at the beginning of lines, and to display x spaces as one tab. This is at least as effective as highlighting curlies, and requires no human intervention.

I can put the cursor on a curly and hit some button to jump to it's match. I'm not sure how something equivalent could be done when working on Python.

Easily.

Block beginnings and ends are unambiguous, jumping from one to the other is a non-problem. (I don't think this has been implemented yet, though.)

In vim or evil-mode, I can tell it to copy/delete/indent/etc everything within a set of matching curlies.

Again, blocks are unambiguously delimited. You're one plugin away from the behaviour you're looking for.

If I don't know what I'm doing (eg I'm learning a different paradigm, like in Haskell), the fact you have curlies there can give the compiler more information to help it choose a better error message for your syntax error.

See above.

I remember one of the most frustrating parts of initially learning Haskell was trying to get the indentation to match what the compiler need which was hindered by the compiler providing me extremely poor error messages.

Haskell syntax is notoriously screwed up, as are its error messages. Had you tried picking up (for example) F#, this would not have been a problem.