64 |
fun sp () = PP.space ppStrm 1 |
fun sp () = PP.space ppStrm 1 |
65 |
val string = PP.string ppStrm |
val string = PP.string ppStrm |
66 |
fun var x = string(Var.nameOf x) |
fun var x = string(Var.nameOf x) |
67 |
|
fun ppIndex (ppStrm, NONE) = PP.string ppStrm ":" |
68 |
|
| ppIndex (ppStrm, SOME i) = var i |
69 |
fun pp e = (case e |
fun pp e = (case e |
70 |
of S.E_Var x => string(Var.uniqueNameOf x) |
of S.E_Var x => string(Var.uniqueNameOf x) |
71 |
| S.E_Lit lit => string (Literal.toString lit) |
| S.E_Lit lit => string (Literal.toString lit) |
75 |
var f; ppTyArgs (ppStrm, mvs); sp(); ppArgs (ppStrm, args)) |
var f; ppTyArgs (ppStrm, mvs); sp(); ppArgs (ppStrm, args)) |
76 |
| S.E_Cons es => ( |
| S.E_Cons es => ( |
77 |
ppList ppVar ("[", ",", "]") (ppStrm, es)) |
ppList ppVar ("[", ",", "]") (ppStrm, es)) |
78 |
|
| S.E_Slice(x, indices) => ( |
79 |
|
var x; |
80 |
|
ppList ppIndex ("[", ",", "]") (ppStrm, indices)) |
81 |
| S.E_Input(ty, argName, NONE) => |
| S.E_Input(ty, argName, NONE) => |
82 |
string(concat["input(\"", argName, "\")"]) |
string(concat["input(\"", argName, "\")"]) |
83 |
| S.E_Input(ty, argName, SOME default) => ( |
| S.E_Input(ty, argName, SOME default) => ( |