UpstandingHackers / hammer

Parser combinators for binary formats, in C. Yes, in C. What? Don't look at me like that.
GNU General Public License v2.0
430 stars 40 forks source link

Make parsers `foo__m` macros that expand to `foo__m(mm__, ...)` #127

Open pesco opened 9 years ago

pesco commented 9 years ago

This is an idea for a possible enhancement. Feedback welcome!

For the default case, a user would globally declare mm__ = &h_system_allocator. In combinators, the standard argument would shadow the global variable.

Benefits:

Cons: