packcc
packcc copied to clipboard
A parser generator for C
I would like to point out that identifiers like “[`PCC_INCLUDED__`](https://github.com/arithy/packcc/blob/1012eb3453c22659a27da8ec08d7fcade7a63a43/src/packcc.c#L1974 "Update candidate")” and “[`STRING_FLAG__IDENTIFIER`](https://github.com/arithy/packcc/blob/1012eb3453c22659a27da8ec08d7fcade7a63a43/src/packcc.c#L244 "Another update candidate")” [do eventually not fit](https://www.securecoding.cert.org/confluence/display/cplusplus/DCL51-CPP.+Do+not+declare+or+define+a+reserved+identifier "Do not declare an identifier which is reserved for...
I suggest to reuse a higher level build system than [your current make scripts](https://github.com/arithy/packcc/commit/27c06965bacb8bb6ef6d59875a7232528a825096 "Update candidate") so that powerful checks for software features will become easier. - [CMake](https://cmake.org/ "Building software...
Hello! Sorry for opening two "issues"- they are not really issues but relate to different topics! What is your thinking concerning re-syncing after a parse/recognition error. I am thinking of...
I'm trying to parse some input into a struct but I don't understand how to use `%value` to get a pointer in and out of the parser. A very stripped-down...
Looking for a ready to use `C` peg grammar I found this one https://github.com/pointlander/peg/blob/master/grammars/c/c.peg and needed to make some changes (see attached) to build and parse the generated `C` file...
AST Mode
Continues the discussion from #51. The main use case for a parser-generator is to build an Abstract Syntax Tree, or AST. Therefore, it would be nice if there were a...
Hello @arithy and @andrewchambers, Here is my unfinished attempt on adding optimization phase to packcc, as I mentioned in https://github.com/arithy/packcc/issues/46#issuecomment-936353311. ## Possible optimizations: - Inline simple terminal symbols (multi pass)...
Antlr supports "import" statements, where you can import an external file and treat its contents as if they were part of the current file. I use this a lot to...