logoalt Hacker News

pgttoday at 10:27 AM2 repliesview on HN

> "I do wish there were an easier way to move in the ]}]})))}-ness of block ends though."

If he means navigating the AST, there is Parinfer: https://shaunlebron.github.io/parinfer/

Paredit / Parinfer ruined other languages for me. It lets you navigate up/down/in/out of the Clojure AST with keyboard commands and mutate those expressions, e.g. "Split" will split open the current data structure you're in: `(a| b)` =Split=> `(a)| (b)`, where | is caret. Join is the inverse, and it works for all data structures.


Replies

stodor89today at 3:11 PM

I type out nowhere near enough code for this to matter, but it's pretty cool nonetheless!

Sharlintoday at 11:27 AM

Indeed. The incredibly clumsy way we choose to edit source code has baffled me since I was first acquainted with parinfer. Having to keep the source in the shape of a valid AST almost entirely manually is really annoying.

show 4 replies