aboutsummaryrefslogtreecommitdiff
path: root/src/lexer.l
diff options
context:
space:
mode:
Diffstat (limited to 'src/lexer.l')
-rw-r--r--src/lexer.l7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/lexer.l b/src/lexer.l
index 74d301a..8100405 100644
--- a/src/lexer.l
+++ b/src/lexer.l
@@ -15,6 +15,8 @@
extern const char *current_file;
%}
+ws [ \t]
+
%%
¬|! { return NOT; }
@@ -29,12 +31,15 @@ extern const char *current_file;
\\ { return '\\'; }
\n { return EOL; }
+ /* Allow line-continuation when the newline is suffixed by a backslash */
+\n{ws}*\\ ;
+
[a-zA-Z] {
yylval.ch = *yytext;
return IDENT;
}
-[ \t]+ ;
+{ws}+ ;
. {
user_error("%s:%d: Unrecognized character ‘%c’",