-
Notifications
You must be signed in to change notification settings - Fork 91
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
bus width alignment #562
Comments
Original Redmine Comment Not presently. Alas as we have a backlog for bugs on the existing styles you'll probably need to implement it yourself. If you can make a patch we'd certainly be willing to take it back. |
Original Redmine Comment BTW to find the logic around this in the sources, look for verilog-auto-lineup. I would suggest adding an additional case to that variable to support this. |
Original Redmine Comment I'll try to do it. wire [7:0] one_dim; reg [WIDTH-1:0][BIT_WIDTH-1:0] two_dim; logic [`MAX_W-1:0][3:0][7:0] tree_dim |
Original Redmine Comment I've had a shot at implementing it in a slightly different way which seems slightly more popular, but didn't get very far with emacs lisp:
This style, however, would also work well with multiple packed dimensions,
So I think it's the better way of doing it - simply right-aligning the packed dimensions, and padding the start of the longest packed dimension description so that it starts after the longest type (logic being the longest type, while the middle one has the longest packed dimension description). |
Author Name: Alex Hornung
Original Redmine Issue: 562 from https://www.veripool.org
Original Date: 2012-09-12
I've started using verilog-mode a few months ago and am overall quite happy with
it. However there is one thing I'm really missing: alignment of the bus
widths (or rather of the square brackets and colons).
I (amongst others) like to format things as follows:
Is there a way to tell verilog-mode to do that automatically, similarly
to how it aligns the names (foo, bar, baz, bla)? If not, would it be possible
to add that?
The text was updated successfully, but these errors were encountered: