Allow unions to be comparable if all their variants are comparable

This commit is contained in:
gingerBill committed 2021-05-03 13:17:16 +01:00
1 parent 77e2e1e1d0
commit 518ecaf9c9
3 files changed
+85 -7

No files matched your search

+3
View File
@@ -121,6 +121,9 @@ Type_Info_Union :: struct {
variants: []^Type_Info,
tag_offset: uintptr,
tag_type: ^Type_Info,
equal: Equal_Proc, // set only when the struct has .Comparable set but does not have .Simple_Compare set
custom_align: bool,
no_nil: bool,
maybe: bool,