Sub-type relation and modes

All QuLog data types are partially ordered by a sub-type relation. For example, each of the system data types nat (the non-negative integers), int (all integers), num (all numbers) is a sub-type of all the types that follow it in the sequence. At the top of the data sub-type tree is term. Every value of a primitive type, or a program defined type, is a term, and every value of the term type is either a value of a system type or a defined type of the QuLog program being queried. A sub-type value may be given as an argument where a super-type is specified. It may also be returned as a value in lieu of a super-type value.