Repository navigation
Require a semicolon after package-scoped event triggers - #1675
Merged
larsclausen merged 3 commits intoOct 28, 2026
Merged
Conversation
The current parser's package-scoped event trigger production does not consume its trailing semicolon. As a result, `if (cond) -> p::e; else ...` is rejected because the semicolon is parsed as a separate null statement. Omitting the required semicolon incorrectly makes the statement compile. Add the semicolon to the package production, matching the ordinary event trigger and the `event_trigger` grammar in IEEE 1800-2023 A.6.5. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
larsclausen
force-pushed
the
parser-package-event-trigger
branch
from
October 28, 2026 04:38
e700bcf to
21170fd
Compare
The current parser accepts `@(p::e)` but rejects `@p::e`. IEEE 1800-2023 A.6.5 permits `@ ps_identifier`, including a package-qualified identifier. Add the package-qualified identifier alternative to `event_control` and construct the same event expression as the parenthesized form. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Check that package-scoped events can be triggered and waited on using `@p::e`. Check triggers used as the direct body of an `if`/`else` statement. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
larsclausen
force-pushed
the
parser-package-event-trigger
branch
from
October 28, 2026 05:08
21170fd to
f935c0b
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The package-scoped event trigger production does not consume its trailing semicolon. As a result,
if (cond) -> p::e; else ...is rejected because the semicolon is parsed as a separate null statement. Omitting the required semicolon incorrectly makes the statement compile.Add the semicolon to the package production, matching the ordinary event trigger and the
event_triggergrammar in IEEE 1800-2023 A.6.5.