firm 'cparser'

As mentioned on llvmdev, the 'firm' project recently released the source (GPL2 license) for their new C parser, named "cparser":

In my brief look at it, it looks even more half baked than Clang :), and (like firm) seems to have an "academic" approach rather than being built with a goal of a fast and fully conformant frontend. It currently doesn't have a preprocessor (though one is in progress), doesn't track column numbers, uses global variables all over the place, does not have an optimized lexer (or anything else), etc. OTOH, it *does* have a man page, and can apparently bootstrap itself! :slight_smile:

I'm not sure why they didn't just use clang, but being written in C++ and/or using a BSD license seems like possible reasons.


AFAIK the main motivation was to not depend anymore on the proprietary
frontend they were using at that time, so libfirm could be useful for more
people (see
I am not even sure they use cparser for their papers (since they work mostly
on code generation).