Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
sv2v
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lvzhengyang
sv2v
Commits
2e43dfee
Commit
2e43dfee
authored
Jan 23, 2022
by
Zachary Snow
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix failed indirection of unassigned function results
parent
4c3dcf52
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
17 additions
and
1 deletions
+17
-1
src/Convert/Scoper.hs
+5
-1
test/core/func_no_asgn.sv
+8
-0
test/core/func_no_asgn.v
+4
-0
No files found.
src/Convert/Scoper.hs
View file @
2e43dfee
...
@@ -520,7 +520,11 @@ scopeModuleItem declMapperRaw moduleItemMapper genItemMapper stmtMapperRaw =
...
@@ -520,7 +520,11 @@ scopeModuleItem declMapperRaw moduleItemMapper genItemMapper stmtMapperRaw =
redirectTFDecl
::
Type
->
Identifier
->
ScoperT
a
m
(
Type
,
Identifier
)
redirectTFDecl
::
Type
->
Identifier
->
ScoperT
a
m
(
Type
,
Identifier
)
redirectTFDecl
typ
ident
=
do
redirectTFDecl
typ
ident
=
do
res
<-
declMapper
$
Variable
Local
typ
ident
[]
Nil
res
<-
declMapper
$
Variable
Local
typ
ident
[]
Nil
let
Variable
Local
newType
newName
newRanges
Nil
=
res
(
newType
,
newName
,
newRanges
)
<-
return
$
case
res
of
Variable
Local
t
x
r
Nil
->
(
t
,
x
,
r
)
Net
Local
TWire
DefaultStrength
t
x
r
Nil
->
(
t
,
x
,
r
)
_
->
error
"redirectTFDecl invariant violated"
return
$
if
null
newRanges
return
$
if
null
newRanges
then
(
newType
,
newName
)
then
(
newType
,
newName
)
else
else
...
...
test/core/func_no_asgn.sv
0 → 100644
View file @
2e43dfee
module
top
;
function
automatic
bit
foo
;
input
integer
x
;
// no return
endfunction
bit
x
;
assign
x
=
foo
(
0
)
;
endmodule
test/core/func_no_asgn.v
0 → 100644
View file @
2e43dfee
module
top
;
wire
x
;
assign
x
=
1'bx
;
endmodule
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