Automatic Enum Stringification in C via Build-Time Code Generation(medium.com)
medium.com
Automatic Enum Stringification in C via Build-Time Code Generation
https://medium.com/@yair.lenga/automatic-enum-stringification-in-c-via-build-time-code-generation-659b67133125
I wrote about autoamtic enum stringification in C - using build-time code generation from the DWARF debug information that is produced by the GCC/Clang compilers. (Medium, no Paywall).
I found the approach to reduce effort and errors for producing debug printout, logging, parsing config files, etc.
At the end, the developer can write something like:
Sharing in the hope that other developer can use this code. Can be integrated into any code with files (".c" source, ".h" header and python code generator) - available on my GitHub (MIT License).
Any feedback will be appreciated.