Hacker News new | ask | show | jobs
by taeric 1403 days ago
Apologies if I was unclear, but this is what I meant. In whitespace languages, you have to see the context.

That said, you can probably make dinner structural editing work roughly the same. Might benefit from highlighting to indicate current scope.

1 comments

Do you mean highlighting like this? https://www.draketo.de/software/wisp-mode-highlighting-seman...

Many parts of structural editing (but not all) become simple indentation shifting with indentation-sensitive languages.

I think so, yes.

And I know many become an indentation shift. This can be a lot more intrusive then just moving a paren. I personally find it harder to match indentation shifts. (Excepting simple one liners, of course.)

I usually do the alignment with tab: my Emacs wisp-mode knows the indentation levels in use in the file, so it’s just shift-tab to go back to the previous scope and tab to nest more deeply.

One observation I made is that wrapping an expression around several lines is often less intrusive, because I can simply insert a line before the block that uses only half the indentation.