summaryrefslogtreecommitdiffstats
path: root/conf
diff options
context:
space:
mode:
Diffstat (limited to 'conf')
-rw-r--r--conf/cf-lex.l5
-rw-r--r--conf/confbase.Y2
2 files changed, 6 insertions, 1 deletions
diff --git a/conf/cf-lex.l b/conf/cf-lex.l
index c6e9a0e..828dfd2 100644
--- a/conf/cf-lex.l
+++ b/conf/cf-lex.l
@@ -137,6 +137,11 @@ WHITE [ \t]
return NUM;
}
+else: {
+ /* Hack to distinguish if..else from else: in case */
+ return ELSECOL;
+}
+
({ALPHA}{ALNUM}*|[']({ALNUM}|[-])*[']) {
if(*yytext == '\'') {
yytext[yyleng-1] = 0;
diff --git a/conf/confbase.Y b/conf/confbase.Y
index ce844ba..68960c2 100644
--- a/conf/confbase.Y
+++ b/conf/confbase.Y
@@ -48,7 +48,7 @@ CF_DECLS
struct timeformat *tf;
}
-%token END CLI_MARKER INVALID_TOKEN
+%token END CLI_MARKER INVALID_TOKEN ELSECOL
%token GEQ LEQ NEQ AND OR
%token PO PC
%token <i> NUM ENUM