summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lex/lexer.mll6
1 files changed, 4 insertions, 2 deletions
diff --git a/lex/lexer.mll b/lex/lexer.mll
index 11779cc75..1eb89c718 100644
--- a/lex/lexer.mll
+++ b/lex/lexer.mll
@@ -119,9 +119,11 @@ and action = parse
string lexbuf;
reset_string_buffer();
action lexbuf }
- | "'{'"
+ | "'" [^ '\\'] "'"
+ { action lexbuf }
+ | "'" '\\' ['\\' '\'' 'n' 't' 'b' 'r'] "'"
{ action lexbuf }
- | "'}'"
+ | "'" '\\' ['0'-'9'] ['0'-'9'] ['0'-'9'] "'"
{ action lexbuf }
| "(*"
{ comment_depth := 1;