Commit ede62577 authored by Guillaume Melquiond's avatar Guillaume Melquiond

Properly count line breaks embedded in strings.

parent 5cae7968
......@@ -290,7 +290,8 @@ and string = parse
Buffer.clear string_buf;
s }
| "\\" (_ as c)
{ Buffer.add_char string_buf (char_for_backslash c); string lexbuf }
{ if c = '\n' then newline lexbuf;
Buffer.add_char string_buf (char_for_backslash c); string lexbuf }
| newline
{ newline lexbuf; Buffer.add_char string_buf '\n'; string lexbuf }
| eof
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment