-
Notifications
You must be signed in to change notification settings - Fork 143
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
Update Parser_expressions.cpp #669
Update Parser_expressions.cpp #669
Conversation
For 'always@( *)' lexed as '@' '(' '*,' , there will be a error for the parser. The commit can correct the error.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the PR. The logic looks good to me, just one small fix to make.
@@ -1135,6 +1135,13 @@ TimingControlSyntax* Parser::parseTimingControl() { | |||
expect(TokenKind::CloseParenthesis)); | |||
} | |||
|
|||
// Special case since @(*) will be lexed as '@' '(' '*)' | |||
if (peek(TokenKind::StarCloseParenthesis)) { | |||
auto startclosePara = consume(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Typo here, should be something like starCloseParen
not "start"
Also it would be good to add a test that exercises this. Probably something simple in ExpressionParsingTests.cpp |
Codecov Report
Additional details and impacted files@@ Coverage Diff @@
## master #669 +/- ##
=======================================
Coverage 91.14% 91.14%
=======================================
Files 186 186
Lines 43172 43180 +8
=======================================
+ Hits 39348 39356 +8
Misses 3824 3824
Continue to review full report at Codecov.
|
Thanks for suggestions. I have corrected the typo and added a test. |
For 'always@( )' lexed as '@' '(' ',' , there will be a error for the parser. The commit can correct the error.