Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix lexer for ONTOLOGY parsing #3091

Merged
merged 4 commits into from
Sep 25, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions src/nmodl/lex.lpp
Original file line number Diff line number Diff line change
Expand Up @@ -179,6 +179,12 @@
return s->type;
}

<ontology>[ \t] {/*ignore spacing characters*/;}

<ontology>. {
diag("Invalid ONTOLOGY syntax: expected 'name' or '[name]'", nullptr);

Check warning on line 185 in src/nmodl/lex.lpp

View check run for this annotation

Codecov / codecov/patch

src/nmodl/lex.lpp#L184-L185

Added lines #L184 - L185 were not covered by tests
}

Check warning on line 187 in src/nmodl/lex.lpp

View check run for this annotation

Codecov / codecov/patch

src/nmodl/lex.lpp#L187

Added line #L187 was not covered by tests
{D}+ { /*INTEGER*/
yylval.qp = putintoken(yytext, INTEGER); /* Numbers are not looked for */
return INTEGER;
Expand Down
Loading