If Pascal doesn't have required exhaustive pattern matching, it's no better than Go or C# in this regard.
C# thankfully was designed by someone that appreciates type systems, maybe you should revisit it.
func f(x StatusCode) {
}
f(728347) // There's no such status. Whateverz, no compile error. f(728347) // There's no such status. Whateverz, no compile error.
a := 728347
f(a) // Compile error.