Finally starting to see a workflow come together i...
# devlog-together
j
Finally starting to see a workflow come together in my editor. Here you can see Fibonacci at three different levels in the language I'm making. These functions live in three different files. Looking at them at once and comparing them isn't easily supported in any other editor I use. On the left is a simplistic symbol browser. I'm super excited that I'm slowly getting to the point where I can do these kinds of things. Having different views of our codebases that we can switch between is something I've been wanting for years.
Also, I'm not actually making a lisp, but rust makes it so easy to make a macro that is a lisp, I always do that for my ASTs well before I write a parser
d
This is three different human-authored versions at different levels?
j
Yes. I wrote them by hand bottom up. The highest level compiles to that lower level. But that isn’t the output of that code.
e
the font’s rendering is really pretty
j
Thanks :) I didn’t do anything special. It’s Ubuntu mono and just let skia do the rendering.
e
at least from this image it looks so much nicer than VS Code out of the box
j
Maybe just the resolution of my screen? They look the same for me in vs code. I've got a 16 inch m2 macbook pro
e
perhaps! It could also my warm feelings towards not VS Code 😆
b
Looking at them at once and comparing them isn't easily supported in any other editor I use.
I'm curious what you mean. All decent editors support horizontal & vertical splits (which are not as flexible as a canvas, but enough to match this screenshot). Is it about each pane being narrowed to a single function, as apposed to arranging 3 long files and scrolling them to ensure the functions stay view? Plus here if a function grows longer, you just zoom out instead of fiddling with scrolling?
j
For me it’s 1) just the function, no other noise. 2) expands and contracts when I edit the function 3) I don’t have to know what file something is in This is of course a super simple example with just three things. Imagine a have a function open and it calls 5 other functions. I can easily show the source of that function and all its dependencies. I can even show a data structure it depends on. I could do this on the canvas next to the code without needing to do any navigation. Want to show how data is flowing? Pull out some functions and draw arrows between them. Yeah you can do splits of files. But that’s not the unit I think at. I want to break up my code in bits and pieces and show how they relate. I want these views to persist. To have notes. To not merely being a moment, but an artifact I can come back to if I want to.
k
> expands and contracts when I edit the function > Oh, did you get rid of each function's scrollbars?
j
Yeah you could still open a file or a function and have it scroll, or not. Your choice. But if the full contents are shown, there is no scroll. But all of this is just at the capabilities + experiments phase. Not final flow