Variant Insecurities Pascal variant records are insecure because it is possible to manipulate the tag independently from the variant contents. These problems were fixed in Ada by requiring tag and variant contents to be set simultaneously, and inserting a runtime check on the tag before any read of the variant contents. Case combines inspection of tag and extraction of values into one operation. More general index sets are seldom supported directly by language because of the lack of a single, uniform, good implementation. Others permit the size independently for each array value, when the array is first created.
Arrays are often large, and hence manipulated by reference.
They may or may not be first-class. Major security issue for arrays is bounds checking of index values. Runtime checks are always possible, but may cost. Functions and Mappings Mathematical mappings can also be represented by an algorithmic formula . A program function can describe an infinite mapping.