Lines Matching defs:types

128        to construct unique identifiers for types depending on the context
159 (* Error message for incompatible types. Displays both expressions and their types. *)
374 types. Returns a type variable if the list is empty.
378 | assignList (processValue: 'a->types, _, _) _ [single] = processValue single
380 | assignList (processValue: 'a->types, displayValue, typeMsg)
468 (* The types of constructors and variables are copied
649 unifies the types. Returns a type variable if the list
655 ("Elements in a list have different types.", "Item", ",", location, aList) elements
733 (* Include this type in the list of instance types. *)
959 (* Add the structure we're opening here to the types of
986 (* First match all the types on the right-hand sides. *)
992 (* Can now declare the new types. *)
1065 (* Copy the types of value constructors replacing
1074 fun copyTyp (t : types) : types =
1110 ("Elements in a list have different types.", "Item", ",", location, aList) elements
1142 | (aFun as Fn {matches, location, expType, ...}) => (* Must unify the types of each of the alternatives.*)
1146 ("Clauses in fn expression have different types.", "Clause", "|", location, aFun) matches
1187 val _ : types = assignSeq(localEnv, newLetDepth, decs, false)
1243 (* Fill in any types. If there was no type given the exception has type exn
1324 ("Clauses in handler have different types.", "Clause", "|", location, aHandler) hrules
1352 ("Clauses in case have different types.", "Clause", "|", location, aCase) match;
1499 processing the patterns is a list of their types. Each item
1526 (* Check that the types match by going down the list of value
1527 bindings and the list of types produced from the patterns,
1528 and matching corresponding types. *)
1565 typeMismatch("Pattern and expression have incompatible types.",
1895 (* Generalise the types. allowGeneralisation side-effects the type variables,
1956 (* First match all the types on the right-hand sides using the
1992 (* Now process the types and generate the constructors. *)
2048 these types. *)
2078 (* We also have to do something similar with types. This is really
2160 general type we have to consider all the types that may be used for
2170 (* Unify the types. If there's an error we return a fresh set of the type
2183 else tyVars (* Return the type vars instantiated to the instance types. *)
2189 of all the instance types that are possible. *)
2197 If we have we use the same ref for each var and merge the instance types. *)
2209 the shared list of instance types. *)
2213 fun reduceTypes(tv, ref types) =
2216 if isSome(unifyTypes(TypeVar tv, leastGeneral(List.map #value types)))
2243 instance types within the bodies. *)
2309 and types = types