decomp-permuter
decomp-permuter copied to clipboard
C++ Support?
Is this out of scope? Surely we can at least have some way of dealing with c++ features like casts and classes and certain c99 inherited features.
It's hard, given the reliance on pycparser. If we restrict ourselves to C++ without templates we could plausibly patch pycparser, but that's a) a fair chunk of work, b) pretty limiting. PERM_IGNORE + PERM_PRETEND can be used to some extent. An option would be to use the clang parser, translate the resutling AST to a pycparser one, and then later translate back. Or alternatively, emit pretty-printed text with lots of PERM_IGNORE.
It would be nice to have a "text mode" for the permuter, where it doesn't make use of the C parser (only supporting PERM macros).