3 ms·
I’m writing a simple “CoffeeScript for C” right now for my CS 283 Systems Programming class’s final project. It’s due in two weeks, but my work so far is on Git
by roryokane 14y ago
I’m writing a simple “CoffeeScript for C” right now for my CS 283 Systems Programming class’s final project. It’s due in two weeks, but my work so far is on GitHub now: https://github.com/roryokane/cs283-final-project https://github.com/roryokane/cs283-final-project. It won’t do much – it will just compile three kinds of syntactic sugar – but I hope to make it composable enough to extend it in the future.
The three syntactic sugars I’m including are these: allow indents instead of {}; automatically add semicolons; remove parentheses from if/while/for conditionals. I’m trying to make my compiler robust enough to not cause problems like JavaScript’s automatic semicolon insertion does.
This project is just CoffeeScript for C for now, but I’m aiming in the future to make a generic “CoffeeScript for C-like languages”, that can be adapted to work with languages like with ActionScript and Java with only minor tweaking.