Comments (16)
Afternoon @LarsAsplund
I am currently away from a computer for the next three weeks, but I can answer some of these questions.
-
It appears there is no rule to force spacing before the assignment operator in port and generic maps. This is a little puzzling to me as I would expect one to exist. I will work on adding a rule when I return sometime after June 2nd.
-
Have you checked the configuration of rule signal_006? There is an option to set the spacing to 1. The default is at least one space to allow for alignment.
-
Have you checked the configuration of rule if_009? It handles alignment of multiline conditions in if expressions. If you disabled all the alignment rules using via a group, You can enable that rule invidually.
Regards,
--Jeremy
from vhdl-style-guide.
I'll respond here since I am the "active" user of this here at the moment.
- It appears there is no rule to force spacing before the assignment operator in port and generic maps. This is a little puzzling to me as I would expect one to exist. I will work on adding a rule when I return sometime after June 2nd.
Appreciate it! :)
- Have you checked the configuration of rule signal_006? There is an option to set the spacing to 1. The default is at least one space to allow for alignment.
We have that one enabled, it doesn't seem to fix the colon around the signal keyword when used in hierarchical references.
- Have you checked the configuration of rule if_009? It handles alignment of multiline conditions in if expressions. If you disabled all the alignment rules using via a group, You can enable that rule invidually.
We have that rule enabled, with align_left: yes
and align_paren: no
, it still seems to put the next row of statements on the same level.
from vhdl-style-guide.
Morning @ru551n ,
We have that one enabled, it doesn't seem to fix the colon around the signal keyword when used in hierarchical references
I reviewed the rule and it should work with hierarchical references. Could you post the output of the following command:
vsg -rc signal_006
We have that rule enabled, with align_left: yes and align_paren: no, it still seems to put the next row of statements on the same level
Maybe I misunderstood the original question. Is the issue the indenting is not working or the structure of the expression (adding or removing carriage returns) the issue?
--Jeremy
from vhdl-style-guide.
I reviewed the rule and it should work with hierarchical references. Could you post the output of the following command:
λ vsg -rc signal_006 -c .vsg.yaml
{
"rule": {
"signal_006": {
"indent_style": "spaces",
"indent_size": 2,
"phase": 2,
"disable": false,
"fixable": true,
"severity": "Error",
"number_of_spaces": 1
}
}
}
from vhdl-style-guide.
Afternoon @ru551n ,
It appears the rule is configured correctly for a single space. I will need to get to a computer before I can debug any further. I will be back from vacation on June 2nd and will take a look at these issues shortly after.
Regards
--Jeremy
from vhdl-style-guide.
Morning @ru551n ,
I have added two new rules to enforce whitespace before port map and generic map assigment operators to branch issue-1170
. This should address the first issue. When you get a chance could you check it out on your end and see if it is working for you.
For the second issue, I have the following code snippet:
1 architecture rtl of fifo is
2
3 signal dut.foo : std_logic;
4
5 begin
6
7 end architecture rtl;
I used the following configuration file:
1 "rule": {
2 "global": {
3 "disable" : true
4 },
5 "signal_006": {
6 "disable" : false,
7 "number_of_spaces" : 1
8 }
9 }
when I run vsg against the file using the configuration I get the following code:
1 architecture rtl of fifo is
2
3 signal dut.foo : std_logic;
4
5 begin
6
7 end architecture rtl;
I must be missing something as rule signal_006
seems to be enforcing a single space before the colon. Could you post a snippet that shows the issue you are seeing?
Regards,
--Jeremy
from vhdl-style-guide.
Afternoon @ru551n ,
Is there a chance you could post a snippet of the third issue? I have my test example and it seems to be working as expected:
1 architecture rtl of fifo is
2
3 signal dut.foo : std_logic;
4
5 begin
6
7 PROC_1:process
8
9 begin
10
11 if condition_a and condition_b then
12 elsif condition_a and
13 condition_b then
14 end if;
15
16 end process PROC_1;
17
18 end architecture rtl;
with this configuration:
1 "rule": {
2 "signal_006": {
3 "disable" : false,
4 "number_of_spaces" : 1
5 },
6 "if_002": {
7 "parenthesis": "remove"
8 },
9 "if_009": {
10 "align_left": true,
11 "align_paren": false
12 }
13 }
yields:
1 architecture rtl of fifo is
2
3 signal dut.foo : std_logic;
4
5 begin
6
7 proc_1 : process is
8 begin
9
10 if condition_a and condition_b then
11 elsif condition_a and
12 condition_b then
13 end if;
14
15 end process proc_1;
16
17 end architecture rtl;
I feel I am missing something on the last issue.
--Jeremy
from vhdl-style-guide.
Morning @ru551n and @LarsAsplund ,
Just wanted to ping you on this issue to see if we can move this forward.
Thanks,
--Jeremy
from vhdl-style-guide.
Related Issues (20)
- Support parallel tests HOT 2
- docs: Typos HOT 3
- Configuration JSON format is not JSON compliant HOT 5
- Remove invalid escape sequences from docstring HOT 6
- Consider removing vsg/rules/__init__.py and vsg/vhdlFile/extract/__init__.py import index files
- Enable pylint in project
- Documentation issues
- Subtype exceptions HOT 6
- pytest occasionally reports an issue but does not fail
- Manifest.in is out of date.
- `Configuring Use Clause Indenting` documentation issue HOT 4
- --vsg_off length_003 does not disable the rule HOT 3
- IndexError: pop from empty list when having lots of parenthesis in a package body HOT 6
- Rule for "space around operators" (?) HOT 8
- Local Rule Creation Documentation HOT 5
- Multiple local_rule Directories HOT 5
- Rule for new lines between end of generic map and port map HOT 5
- Prefix/suffix exceptions not exempted from case checking in instantiation_008 HOT 6
- Rule concerning label presence after end keyword on component declaration HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from vhdl-style-guide.