File tree Expand file tree Collapse file tree 3 files changed +5
-5
lines changed
core/src/main/scala/dfhdl/core
lib/src/test/scala/docExamples/ugdemos/demo5 Expand file tree Collapse file tree 3 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -114,7 +114,7 @@ object DFIf:
114
114
if (hasNoType || branchTypes.forall(_.isSimilarTo(branchTypes.head)))
115
115
val retDFType = if (hasNoType) ir.DFUnit else branchTypes.head
116
116
val DFVal (headerIR : DFIfHeader ) = header : @ unchecked
117
- val headerUpdate = headerIR.copy(dfType = retDFType)
117
+ val headerUpdate = headerIR.copy(dfType = retDFType.dropUnreachableRefs )
118
118
// updating the type of the if header
119
119
headerIR.replaceMemberWith(headerUpdate).asValAny.asInstanceOf [R ]
120
120
else // violation
Original file line number Diff line number Diff line change @@ -84,7 +84,7 @@ object DFMatch:
84
84
case DFUnit => firstCaseRet.get
85
85
case _ =>
86
86
val DFVal (headerIR : DFMatchHeader ) = header : @ unchecked
87
- val headerUpdate = headerIR.copy(dfType = retDFType.asIR)
87
+ val headerUpdate = headerIR.copy(dfType = retDFType.asIR.dropUnreachableRefs )
88
88
// updating the type of the match header
89
89
headerIR.replaceMemberWith(headerUpdate).asValAny.asInstanceOf [R ]
90
90
else
Original file line number Diff line number Diff line change @@ -53,7 +53,7 @@ enum ShiftDir extends Encode:
53
53
lshifter.shift <> shift
54
54
rshifter.iBits <> iBits
55
55
rshifter.shift <> shift
56
- dir match
57
- case ShiftDir .Left => oBits := lshifter.oBits
58
- case ShiftDir .Right => oBits := rshifter.oBits
56
+ oBits := dir match
57
+ case ShiftDir .Left => lshifter.oBits
58
+ case ShiftDir .Right => rshifter.oBits
59
59
end LRShiftDirect
You can’t perform that action at this time.
0 commit comments