arithy / packcc

A parser generator for C
Other
349 stars 29 forks source link

cannot match backslash #26

Closed aep closed 3 years ago

aep commented 3 years ago

matching backslash doesn't seem to be possible

file <- '\\' EOL
EOL <-  ("\r\n"  / "\n" / "\r" )

input

\
aep commented 3 years ago

as a workaround, matching '\x5c' works fine

dolik-rce commented 3 years ago

You're right, support for escaping backslash was missing.

aep commented 3 years ago

great, thanks