Hacker News new | ask | show | jobs
by Joker_vD 2058 days ago
I believe it's also 1 or 2 shortcuts, thanks to the IDE's understanding of the language syntax, unless I misunderstood your scenario?

> Besides, a Lisp editor can blur the parentheses so users don't mentally have to.

Besides, another languages can throw away the parentheses entirely so neither users nor editors don't mentally or visually have to.

2 comments

> I believe it's also 1 or 2 shortcuts, thanks to the IDE's understanding of the language syntax, unless I misunderstood your scenario?

I have not seen transposing, merging, splitting, annexing (moving a block into the inside another block), and de-annexing (the opposite of annexing) 2 blocks of codes in JS without using the mouse yet, so I just want to check.

> Besides, another languages can throw away the parentheses entirely

JS uses parentheses for grouping complex arithmetics and for function's argument lists (eg. func(arg) in JS vs. (func arg) in lisp). JS also uses curly braces to mark code blocks, which is similar to Lisp parentheses but at the cost of more complex parsing for the compiler and the mental distinguishing between functions' argument lists and code blocks on the coder (they are just lists).

JS statements use semi-colons, which makes editing them feel like editing lines of codes while editing Lisp statements is editing nodes of a tree, which is a very different experience.

> Besides, another languages can throw away the parentheses entirely so neither users nor editors don't mentally or visually have to.

Which mainstream languages have no brackets?