eliben/pycparser
View on GitHub ↗ ★ 3,579 Python
:snake: Complete C99 parser in pure Python
8 mentions on Hacker News by 5 people: 2 stories, 6 comments · first 2013-07-17 · latest 2022-10-14
20082026
-
▲ 1
Complete C99 parser in pure Pythonstory by linkdd · 2022-10-14 · 0 comments
-
https://github.com/eliben/pycparser
comment by linkdd · 2022-10-14 · in Tinyphysicsengine: Minimalist 3D C99 single-header physics engine -
…You can however work around most of them by -D defining them to empty macro in the argument. [0] https://github.com/eliben/pycparser
comment by G4E · 2022-09-14 · in Cake – A C23 compiler frond end written from scratch in C -
…with writing and compiling the stub for every platform. This is why pycparser exists, for example. https://github.com/eliben/pycparser
comment by lvh · 2018-01-08 · in How the JVM compares strings on x86 using pcmpestri -
▲ 1
Breaking the internet with python broken python depsstory by tbarbugli · 2016-10-18 · 0 comments
-
Here's a complete C frontend that uses the lex/yacc approach - https://github.com/eliben/pycparser (the Python ports of them, that is) FWIW, if I had to do this again today I would certainly go for hand-written recursive descent. lex/yacc…
comment by eliben · 2015-12-14 · in How I wrote a self-hosting C compiler in 40 days -
pycparser ( https://github.com/eliben/pycparser ) - a complete front-end for C99 in pure Python. Used in production by tools like cffi.
comment by eliben · 2013-11-06 · in Ask HN: What open source project is your pride and joy? -
…signs, floating point dots, type specifiers (U, L, etc.), and much more. For the gory details see: https://github.com/eliben/pycparser/blob/master/pycparser/c_... But in the end, it's all in the same token.
comment by eliben · 2013-07-17 · in Hand-written lexer in Javascript compared to the regex-based ones