Allow same-name reserved and renameable signals to merge during synthesis - #712
Merged
Merged
Conversation
Contributor
|
Looks like it was a naming bug before ! :) I don't quite see why the three-signal chain is enough to test this completely. Are there any chaining combinations that could block (I don't see that many permutations in the tests). |
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.
Description & Motivation
Allow connected, equivalent
Naming.reservedandNaming.renameablesignals to share a generated declaration when all preserved names match exactly in the module's namespace before uniquification. This applies to internal signals and port aliases, including chains with mixed naming modes.Previously, these connections could generate redundant uniquified aliases or throw reserved-name collision errors despite representing the same signal. The updated contract preserves a generated name without requiring a separate declaration for every original signal.
Merged groups retain every original
Logicand its mappings. Different preserved names remain separate, unrelated reserved-name collisions still fail, and unrelated renameable signals are still uniquified. Module interfaces and structural merge restrictions remain protected.Related Issue(s)
None linked.
Testing
Backwards-compatibility
Somewhat, but it shouldn't be in a meaningful way. This changes the documented naming behavior and may change generated identifiers and declarations. Equivalent same-name preserved signals may now share a declaration, and connected same-name reserved signals no longer trigger collision errors. Downstream scripts or tests that depend on separate generated aliases or the previous collision errors may need updates. No Dart API signatures change.
Documentation
Yes. Updated the
NamingAPI doc comments, synthesis merge doc comments, and the generation user guide to explain the name-preservation contract and its restrictions. Included a changelog entry under Next Release.