Open
Conversation
Some VHDL preprocessors may use @@ for their own callouts, so use a different prefix internally lest we filter out those callouts.
To work around VHDL's strict comma rules in PORT MAP and GENERIC
MAP statements and allow simple copy-pasting of new ports near
the end of the port map, designers sometimes write this:
PORT MAP (
port1 => '1'
,port2 => '0'
,port3 => open
)
Add a regex to undo this hack and move the comma back to the end
of the previous line.
The regexes that detect an assignment statement did not match on vector assignments with a range, such as vector(0 to 2) <= some_input or some_other_input; and as such the continuation lines did not get indented at all. Fix this by adding loose matches for bit ranges to the regexes.
During processing of multiline assignments, add a marker in line with the assignment, then during sign alignment align those markers together with the actual assigment. As a side effect, global sign alignment no longer ends the current aligned block on every multiline assignment but now treats multiline assignments the same way as single line assignments, grouping consecutive groups of assignments into a single aligned block.
Contributor
Author
|
Let me know if you'd like me to create issues for the indentation fixes. |
Owner
|
Thanks for this PR. I noticed that one unit test failed ( CONSTANT Vcc : SIGNAL := --logic 1 constant
'1';
CONSTANT zero4 : bit_vector(0 TO 3) :=--test
('0', '0', '0', '0');The expected behavior would be: CONSTANT Vcc : SIGNAL := --logic 1 constant
'1';
CONSTANT zero4 : bit_vector(0 TO 3) := --test
('0', '0', '0', '0'); |
Contributor
Author
|
Sorry for the long delay, busy with other work stuff right now :/ |
Owner
|
I've added the jest into the github action. So if you merge master into your pr, github will check for you automatically. |
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.
Improve indentation around multiline assignments, comma fixup feature, plus some minor updates.