If you have ever used something like yacc/bison, debugging it is relatively sane with gdb.
You can find all the possible tricks in making it debuggable by reading the y.tab.c
Including all the corner cases for odd compilers.
Re2c is a bit more modern if you don't need all the history of yacc.