Fix escaped quotes and includes in tokenizer

This commit is contained in:
Mikaël Bouillot 2017-05-02 09:26:27 +02:00
parent 9c2cf2cf86
commit 362264b2a5

View file

@ -149,7 +149,7 @@ case $cmd in
git cat-file blob $ref 2>/dev/null |
tr '\n' '\1' |
perl -pe 's%((/\*.*?\*/|//.*?\001|".*?"|#include *<.*?>|\W)+)(\w+)?%\1\n\3\n%g' |
perl -pe 's%((/\*.*?\*/|//.*?\001|"(\\"|.)*?"|# *include *<.*?>|\W)+)(\w+)?%\1\n\4\n%g' |
head -n -1
;;