(* mid-il.sml * * COPYRIGHT (c) 2010 The Diderot Project (http://diderot.cs.uchicago.edu) * All rights reserved. * * Middle-level version of the Diderot IL. * * Note: this file is generated from gen/mid-il.spec and gen/mid-il.in. *) structure MidOps = struct datatype ty = BoolTy | StringTy | IntTy | TensorTy of int list fun samety (ty1 : ty, ty2) = (ty1 = ty2) fun hashty BoolTy = 0w1 | hashty StringTy = 0w2 | hashty IntTy = 0w3 | hashty (TensorTy dd) = List.foldl (fn (d, s) => Word.fromInt d + s) 0w4 dd fun tyToString BoolTy = "bool" | tyToString StringTy = "string" | tyToString IntTy = "int" | tyToString (TensorTy dd) = String.concat[ "tensor[", String.concatWith "," (List.map Int.toString dd), "]" ] fun samestring (s1 : string, s2) = (s1 = s2) val hashstring = HashString.hashString fun stringToString s = String.concat["\"", s, "\""] @BODY@ end structure MidIL = SSAFn(MidOps)
Click to toggle
does not end with </html> tag
does not end with </body> tag
The output has ended thus: fun stringToString s = String.concat["\"", s, "\""] @BODY@ end structure MidIL = SSAFn(MidOps)