Changes between Version 67 and Version 68 of IR
- Timestamp:
- 11/26/15 07:14:29 (10 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
IR
v67 v68 107 107 **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. 108 108 109 **Value 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.109 **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. 110 110 111 111 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]`. … … 156 156 * `\implies(e1,e2)`: logical implication. Short-circuiting. 157 157 * `\eq(e1,e2)`, `\neq(e1,e2)`: equality/inequality test 158 * `\forall <i1:T1,i2:T2,...>, e` : universal quantification. For all i1 in type T1, i2 in type T2, ..., e2 holds.159 * `\exists <i1:T1,i2:T2,...>, e`: existential quantification. There is some i1 in type T1, i2 in type T2, ..., such that e holds.158 * `\forall(<i1:T1,i2:T2,...>,e)` : universal quantification. For all i1 in type T1, i2 in type T2, ..., e2 holds. 159 * `\exists(<i1:T1,i2:T2,...>,e)`: existential quantification. There is some i1 in type T1, i2 in type T2, ..., such that e holds. 160 160 Numeric 161 161 * 123, -123, 3.1415, etc. : values of type `Integer`, `Int`, `Real`, `Float`. **NEED TO BE MORE SPECIFIC** … … 177 177 * `\hasnext(dom, <i,j,…>)`: an expression of boolean type, testing if the domain `dom` contains any element after `<i,j,...>` 178 178 Arrays 179 * `\array(T, <e0,...,en-1>)`: value of type `Array[T, n]`, a literal array179 * `\array(T,<e0,...,en-1>)`: value of type `Array[T, n]`, a literal array 180 180 * `\array(T,n,e)`: value of type `Array[T,n]` in which each of the n elements is `e` 181 181 * `\asub(e1,e2)` : array subscript expression. Note that `e1` must have array type, not pointer type. (This is different from C.) If `e1` has pointer type, use `\deref(\padd(e1, e2))` instead.
