Latest posts tagged with #badlang on Bluesky
Do you ever wake up and think? "wouldn't it be fun to make a sample player for the #PlayDate console in your own programming language?" #PLDev #badlang
A terminal screen showing some code and a playdate simulator with the resulting output.
For a few weeks I've started working on my compiler and building some fun stuff I'd like to share soon. In the meantime, with some small adjustments, now I can run #badlang on the Playdate, calling code from C, and viceversa. It's good to be back!
Badlang code with some conditional expression and the linear IR it produces.
Work continues on the self-hosted implementation. A good chunk of the typechecking is done and am currently working on compilation to a linear IR that uses different basic blocks per function but is not on an SSA form. Trying to keep things simple for now.
#PLDev #Badlang
AST of the self-hosted implementation of a parser and the code that generates it
My self-hosted parser can now fully parse itself
#PLDev #badlang
badlang code and the equivalent AST representation, where multiple nodes are connected with nice looking arrows.
Still lots to do, but the self-hosted parser is shaping up!
#pldev #badlang
a couple of expressions on a badlang program alongside the AST it generates, visualized with graphviz
A while ago I saw some amazing threads by @katef.bsky.social on "The Bad Place" where they advocated for printing the internal state of your compiler with graphviz. I was very impressed and been ever since trying to incorporate it in my work. It's back now on the self-hosted compiler #badlang #PLDev
I have imports on my language... I may have gotten a bit ahead of myself and ported most of Raylib's binding by hand... Definitely better to write some scripts for porting bindings in the future lol.
git.badd10de.dev/bdl/tree/exa...
#PLDev #badlang
Got far enough on my compiler today to be able to write the game of life using raylib. I'm so excited to be able to just link to libraylib.a and have this work without any other dependencies (the magic of compiling to C!). thanks @raysan5.bsky.social for making this amazing library!
#PLDev #badlang