From: Francis Dupont Date: Fri, 18 Nov 2016 01:55:09 +0000 (+0100) Subject: [5014] Count embbeded \n in comments X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=638f6b7aa90f40fee0359be30490154d804e301a;p=thirdparty%2Fkea.git [5014] Count embbeded \n in comments --- diff --git a/src/bin/dhcp6/dhcp6_lexer.ll b/src/bin/dhcp6/dhcp6_lexer.ll index 6742b74027..a029257e2f 100644 --- a/src/bin/dhcp6/dhcp6_lexer.ll +++ b/src/bin/dhcp6/dhcp6_lexer.ll @@ -116,7 +116,7 @@ JSONString \"{JSONStringCharacter}*\" } "*/" BEGIN(INITIAL); -.|"\n" ; +. ; <> { isc_throw(isc::BadValue, "Comment not closed. (/* in line " << comment_start_line); } @@ -125,6 +125,7 @@ JSONString \"{JSONStringCharacter}*\" // Ok, we found a with space. Let's ignore it and update loc variable. loc.step(); } + [\n]+ { // Newline found. Let's update the location and continue. loc.lines(yyleng);