pkubowicz / opendetex

Improved version of Detex - tool for extracting plain text from TeX and LaTeX sources
Other
236 stars 35 forks source link

Support escaped percent sign #70

Closed glugg23 closed 3 years ago

glugg23 commented 3 years ago

I ran into this issue today where \% was being ignoring and not printing a percent sign back.

I've got a basic fix here but I'm not entirely sure if this is a full fix. I've added a test file for this behaviour as well as showing that comments are still removed as expected.

Running make test shows that all tests still pass. Running ./test.pl --valgrind shows that all tests pass without leaking memory. However I can't seem to get ./valgrind.sh to work, for some reason it fails to compile but that is not a result of the code I've added.

pkubowicz commented 3 years ago

Thanks!