Skip to main content


So, @lynn wrote a C to #uxn compiler, which allows anyone to write graphical varvara roms in plain C. This setup, where instead of having only the typical main() entry, you also have event bindings as you would in something like Unity(on_button, on_update, etc), is very nice.
https://github.com/lynn/chibicc
#uxn @Lynn
This entry was edited (1 year ago)
in reply to Devine Lu Linvega

With chibicc supporting most of C11, this is just super-cool.
in reply to retroprom

@retroprom I should say that we worked off a slightly older and more stripped-down version of chibicc, which doesn't support, say, bitfields or VLAs or varargs. But it does support all the normal boring stuff 😀
in reply to Lynn

@retroprom I was wondering, how hard would it be to compile the compiler into a tal file? If I could have a chibicc.rom, that would be truly amazing.
in reply to Devine Lu Linvega

@retroprom I've been thinking about it! Syntactically, the largest hurdles left would be supporting `unsigned` and printf/varargs. The compiler also uses `long`, or at least depends on `int` being 32 bits or wider, in certain places. I also fear it allocates much more than 64kB of memory when compiling anything non-trivial — this would probably be the largest hurdle.
This entry was edited (1 year ago)
in reply to Lynn

@retroprom ah yes of course, mhmm I wonder if there could be a way to handle this somehow. I'll think on this, maybe something can be done on varvara's end to accomodate.
in reply to Devine Lu Linvega

Looks like a great tool to help with learning Tal as well. Pulling apart generated code and rewriting from scratch it can serve sort of like unit tests for test driven development.
in reply to Devine Lu Linvega

Cool. I saw your post about that. I’ve been preoccupied with my new gig that I’ve not been doing any personal projects, but the combination of all these new tools is firing me up.

Lo, thar be cookies on this site to keep track of your login. By clicking 'okay', you are CONSENTING to this.