Skip to content

Commit

Permalink
Simplify
Browse files Browse the repository at this point in the history
  • Loading branch information
DanielGavin committed Jul 25, 2024
1 parent 18afea3 commit 921a29d
Showing 1 changed file with 3 additions and 8 deletions.
11 changes: 3 additions & 8 deletions src/server/generics.odin
Original file line number Diff line number Diff line change
Expand Up @@ -151,10 +151,8 @@ resolve_poly :: proc(
case ^ast.Dynamic_Array_Type:
if call_array, ok := call_node.derived.(^ast.Dynamic_Array_Type); ok {

a_soa := common.dynamic_array_is_soa(p^)
b_soa := common.dynamic_array_is_soa(call_array^)

if (a_soa || b_soa) && a_soa != b_soa {
if common.dynamic_array_is_soa(p^) !=
common.dynamic_array_is_soa(call_array^) {
return false
}

Expand Down Expand Up @@ -192,10 +190,7 @@ resolve_poly :: proc(
if call_array, ok := call_node.derived.(^ast.Array_Type); ok {
found := false

a_soa := common.array_is_soa(p^)
b_soa := common.array_is_soa(call_array^)

if (a_soa || b_soa) && a_soa != b_soa {
if common.array_is_soa(p^) != common.array_is_soa(call_array^) {
return false
}

Expand Down

0 comments on commit 921a29d

Please sign in to comment.