3 ms·
If you want to use C as intermediate language, you may be interested in the CIL project[1]. It stands for "C intermediate language"--might be relevant :P. Fund
by tikhonj 13y ago
If you want to use C as intermediate language, you may be interested in the CIL project[1]. It stands for "C intermediate language"--might be relevant :P.
Fundamentally, CIL is a nice subset of C wrapped up into a nicely usable API. The idea is to shave off as many of C's inconsistent sharp edges as possible. You won't have to worry about quirks in the syntax or odd behavior because you have a nice high-level, curated API for generating C code.
It's designed to have a clean semantics, and semantics are very important. (Or so I maintain.)
[1]: http://www.cs.berkeley.edu/~necula/cil/ http://www.cs.berkeley.edu/~necula/cil/
- mkehrt 13y agoI've used CIL (if only for school projects), and I can vouch for it being a joy to use, at least if you like OCaml. Also, their page on wacky C edge cases ("Who says C is simple?", link to frame contents: http://www.cs.berkeley.edu/~necula/cil/cil016.html" http://www.cs.berkeley.edu/~necula/cil/cil016.html") is great.