ignore shebang (#134)

This commit is contained in:
Yuichi Nishiwaki 2014-06-17 21:28:20 +09:00
parent 3bc12d883e
commit e88617a065
1 changed files with 4 additions and 0 deletions

View File

@ -33,6 +33,9 @@
%option extra-type="struct parser_control *" %option extra-type="struct parser_control *"
%option never-interactive %option never-interactive
/* shebang */
shebang #!.*$
/* comment */ /* comment */
comment ;.*$ comment ;.*$
@ -71,6 +74,7 @@ label #{uinteger}
[ \t\n\r] /* skip whitespace */ [ \t\n\r] /* skip whitespace */
{comment} /* skip comment */ {comment} /* skip comment */
{shebang} /* skip shebang */
"#|" { "#|" {
BEGIN(BLOCK_COMMENT); BEGIN(BLOCK_COMMENT);