Commit 40c2e32e authored by Michael Vrána's avatar Michael Vrána

isCastable unspecifiedType fix

parent 31f96a6e
Pipeline #80398 passed with stages
in 11 minutes and 43 seconds
......@@ -155,7 +155,6 @@ export const algorithmReducer = (
if (
fromType !== undefined &&
toType !== undefined &&
![fromType, toType].includes('abstraction::UnspecifiedType') &&
!isCastable(fromType, toType)
) {
incompatibleEdges = incompatibleEdges.add(newEdge)
......
......@@ -19,5 +19,6 @@ algorithms
})
export const isCastable = (from: AlibType, to: AlibType) =>
[from, to].includes('abstraction::UnspecifiedType') ||
removeTemplate(from) === removeTemplate(to) ||
casts[removeTemplate(from)]?.includes(removeTemplate(to))
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment