I was told on Reddit that font-lock-studio will help me debug a matcher I was working on, however, I find myself with one more problem than before as I need to learn edebug and also grasp how to debug my font-lock keywords with font-lock-studio.
Thus, I thought maybe setting up something like behavioral tests on the matcher function to help me with the debugging and testing of the matcher itself as I don't exactly know what am I doing (doing right or wrong, to be honest).
At some point, the matcher use set-match-data
for the resulting matches, I was wondering if there was a way to get that data in order to compare it with the results I'm looking (match-data
is the way to go? Because I eval it after executing manually the matcher function and the values I see makes no sense to me), and also a way to setup a test for the matcher function that can be run at a command.
font-lock-keywords
, to understand the possible formats? Have you read the doc aboutmatch-data
? (If not, that's probably the place to start.) Have you looked at some examples that use font-lock? And please consider showing what you have tried, stating what the result was, and what you expected to see instead.