Skip to content

CAT 016

unurgunite edited this page Jul 11, 2026 · 3 revisions

CAT-016 — Large union types

Field Value
Severity info
Confidence medium
Auto-fix

Large union types — Large union types (e.g., 10+ types) generate slow dispatch code. Consider using a hierarchy or reducing variants.

Bad code

alias Many = Int32 | String | Float64 | Symbol | Nil | Bool | Char | Array(Int32) | Hash(String, Int32) | Tuple(Int32, Int32)

Clone this wiki locally