Open DogWaterDev opened 5 months ago
so maybe nobody wants to do this (or nobody saw this) so i'm gonna start working on this now, as i finished the lexer
im so lazy it's crazy... i have like 2 hours to maybe do this (i suck at programming) so i will work on this but im a bit lost rn pray for me y'all
mb mb im two tired
Abstract Syntax Trees are hard to visualize without a pretty printer for them.
It will be difficult to debug the compiler without any method for this, as you'd have no idea why the compiler fails.
Declarations, Expressions, and Statement could also be difficult to visualize without this feature
Pretty print function for ASTs could look something like this:
Or more like this:
The first method is easier to read, but likely much harder to implement (guesstimating)
The second method is harder to read, but seems easier to implement (guesstimating)
If you want to try this, just fork the repo and send a PR. The most recent version of the code is all in the 'master' branch.