Lines Matching refs:function

58        polymorphic function is wrapped in a function that passes the type
174 print function will be used in polymorphic functions so must print "?". *)
176 val codeFn = mkProc(codePrettyString "fn", 1, "print-function", [], 0)
183 val printFn = (* Create a function to load the printer ref and apply to the args. *)
306 | FunctionType _ => SOME(fn _ => functionCode, ~1) (* Every function has the same code. *)
368 (* Apply the function we obtained to any type arguments. *)
420 (* Apply the function we obtained to any type arguments. *)
509 [] => (* Create a function that, when called, will extract the function from
516 | _ => (* Construct a function, that when called, will extract the
517 function from the reference and apply it first to the
607 | FunctionType _ => mkProc(codePrettyString "fn", 1, "print-function", [], 0)
619 (* Generate an equality function for a datatype construction. *)
638 (* We need a type value here. The equality function will be used to compare
661 (* Apply the function we obtained to any type arguments. *)
702 (* Have to turn this into a new function. *)
719 | _ => raise InternalError "Equality for function"
800 "injection function" of a nullary constructor is the
851 (* Call the second function with the values to be compared and the base types. *)
867 be a function to ensure it's valid inside mkMutualDecs. *)
873 (* Create a printer function for a datatype when the datatype is declared.
1069 type as implementation. The equality function is inherited whether the type
1070 was specified as an eqtype or not. The print function is no longer inherited.
1071 Instead a new reference is installed with a default print function. This hides
1073 (* If this is a type function we're going to generate a new ref anyway so we
1084 else (* We need a function that takes two arguments rather than a single pair. *)
1129 (* Create a print function.*)
1156 (* We hide the print function if the target is just a type name but if the target
1157 is a datatype it's probably better to have a print function. We inherit it
1194 (* Each entry has an equality function and a ref to a print function.
1202 (* If this is polymorphic make two addresses, one for the returned equality function and
1203 one for the inner function. *)
1212 (* Create the typeId values and set their addresses. The print function is
1265 (* Exported function. Returns a function from an ML pair of values to bool.
1270 (* The final result function must take a single argument. *)
1274 (* We need to wrap this up in a new inline function. *)
1298 printing function as a functor argument. *)
1306 (* If we need either the equality or print function we generate a new
1327 else (* If we don't require the equality or print function we can use the cache. *)