Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
Kestrel Collaboration
Kestrel LiteX
migen
Commits
b0c5b74c
Commit
b0c5b74c
authored
12 years ago
by
Sebastien Bourdeauducq
Browse files
Options
Download
Email Patches
Plain Diff
verilog: handle default in case statements
parent
512655c1
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
0 deletions
+4
-0
migen/fhdl/verilog.py
migen/fhdl/verilog.py
+4
-0
No files found.
migen/fhdl/verilog.py
View file @
b0c5b74c
...
@@ -65,6 +65,10 @@ def _printnode(ns, level, comb, node):
...
@@ -65,6 +65,10 @@ def _printnode(ns, level, comb, node):
r
+=
"
\t
"
*
(
level
+
1
)
+
_printexpr
(
ns
,
case
[
0
])
+
": begin
\n
"
r
+=
"
\t
"
*
(
level
+
1
)
+
_printexpr
(
ns
,
case
[
0
])
+
": begin
\n
"
r
+=
_printnode
(
ns
,
level
+
2
,
comb
,
case
[
1
])
r
+=
_printnode
(
ns
,
level
+
2
,
comb
,
case
[
1
])
r
+=
"
\t
"
*
(
level
+
1
)
+
"end
\n
"
r
+=
"
\t
"
*
(
level
+
1
)
+
"end
\n
"
if
node
.
default
.
l
:
r
+=
"
\t
"
*
(
level
+
1
)
+
"default: begin
\n
"
r
+=
_printnode
(
ns
,
level
+
2
,
comb
,
node
.
default
)
r
+=
"
\t
"
*
(
level
+
1
)
+
"end
\n
"
r
+=
"
\t
"
*
level
+
"endcase
\n
"
r
+=
"
\t
"
*
level
+
"endcase
\n
"
return
r
return
r
else
:
else
:
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment