Generally, each array element will need to be tagged with the correct type. Strong Typing A language is said to be strongly typed if all type errors can be statically detected. To maintain whatever security type-checking of primitive types gives us, we must insist at a minimum that T1 and T2 are structurally equivalent . Cartesian product types are equivalent if their corresponding component types are equivalent. Disjoint union types are equivalent if their corresponding component types are equivalent.
Recursive types are a problem.
As a way of improving program correctness by subdividing values into types according to their meaning within the program. For this to be useful, some structurally equivalent types must be treated as inequivalent . Most languages use mixed solutions. The original Pascal definition is vague. The types of x, y, z are all different, but z and w are the same.