I am interested in how compilers work, so I started looking down the rabbit hole of what they actually do, and in what contexts. At this point I had already written a bunch of C, C++, Python, and C#, as well as I was familiar with the idea of scripting languages, interpreters, etc. I was less interested in learning how the C compiler works and more in how does someone take code and convert it to program. The first things I started seeing were parsers, and I eventually stumbled on to an episode of Handmade Hero that went over a basic concept of struct preprocessing. I found this to be very interesting because at the time I was constantly writing out little modern json for c++ blobs for all the new components in Galaxy Golf and I was tired of having to update the save and load functions every single time I wanted another value in my component. I was looking for random little projects to write in C and this felt like a great opportunity. So I started working on a program that used an empty macro as a tag to tell my program to serialize the next structure. I would add my program as a build step to go through the code base and attempt to parse the C structures from the text and then write the equivalent fread and fwrite functions to serialize the entire struct into a File. I was messing around with a Windows XP computer I bought and set up in my office and wrote about 75% of the code for cocopreprocessor on that machine using Microsoft Visual C++ 6.0. Man that compiler is fast as hell! If only it didn't crash every 45 minutes or so on my old machine. This was really fun because I wrote most of the code entirely offline using the old school docs that came with it. What I was left with was about 1500 lines of code that tokenize c style structs, resolve some macros (for array sizes inside of the structs), and give me the read write functions for it. I haven't got a chance to use this in a code base of my own yet, but it handles 99% of the things I use in a struct, so I don't have any reason not to!