Changes between Version 102 and Version 103 of IR
- Timestamp:
- 11/30/15 11:20:41 (10 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
IR
v102 v103 128 128 * `Union[<T0, T1, ...>]`: union type, the disjoint union of `T0`, `T1`, ... 129 129 * `Array[T]` : arrays of any length whose elements belong to T 130 * Note: there is also a dynamic type `Array[T,n]`, signifying arrays of length n. That is a subtype of the dynamic type of `Array[T]`. 130 131 * `Function[<T0,T1,...>,T]` : functions consuming `T0`,`T1`,... and returning `T`. `T` can be `void` to indicate nothing is returned. 131 132 * `Mem` : type representing a memory set. May be thought of as a set of pointers. … … 140 141 **Static types** are the types assigned to variables in a program statically. A static type contains no values anywhere in the type tree. That is, there is no array length expression in the type. These are the types that are used in declarations. Each variable is declared to have some static type. 141 142 142 **Value types** (aka **dynamic types**) are the types associated to values. They include all the static types plus possible length expressions. A value type refines a static type if when you delete the values from the value type you get the static type.143 **Value types** (aka **dynamic types**) are the types associated to values. They include all the static types plus possible array lengths. A value type refines a static type if when you delete the values from the value type you get the static type. 143 144 144 145 A **type name** is a syntactic element that names a (static or value) type. Examples of type names include `Array[Integer]` and `Array[Integer,24]`.
