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

User-defined pretty printers #119

Open mrdomino opened 9 years ago

mrdomino commented 9 years ago

It'd be nice to enable users to tell hammer how to print their types. Maybe add a predicate type for it.

This is necessary, unless I'm missing something, for benchmarking of parsers with user-defined types.

thequux commented 9 years ago

I like this idea, and it could fairly easily be done by making h_pprint table driven. I'll look at that tomorrow.