5 ms·
I came up with the idea of a structure editor independently. I am still very excited about the possibility but there are still some major challenges. 1) Viewi
by bcheung 11y ago
I came up with the idea of a structure editor independently. I am still very excited about the possibility but there are still some major challenges.
1) Viewing code in a tree can be much more verbose and require more cognitive load. I would much rather see "x = a + b" than (set 'x (+ a b)).
2) Languages contain syntactic sugar. Trees do not. That syntactic sugar goes a long ways towards making things easier.
3) Text based code can be very compact. Trees tend to require lots of space on the screen. They can be compacted using s-expressions but I've always found them cumbersome to read -- especially when things get nested.
4) Trees follow prefix format. Sometimes infix and postfix styles are much easier to read.
"someString" capitalize map fn
is much easier to read than
(map (capitalize "some string") fn)
Trees require you to descend to the leaf node and read backwards sometimes.
- abhishivsaxena 11y agome too! 1) Good ui/ux along with a nice color theme can help a lot. 2) What if it's actually just a lisp variant? 3) Very true. 4) Lisp like macros might help with it?
- vinodkd 11y ago#3 is why text still wins. text has high information density, which helps when you have lots of code to deal with. That, and the fact that every environment has a text editor - especially terminal consoles. You can overcome the second factor, but you cannot overcome the first one that easily.