equal
deleted
inserted
replaced
58 |
58 |
59 datatype destination = Compile | Export | File of Path.T | String of string list; |
59 datatype destination = Compile | Export | File of Path.T | String of string list; |
60 type serialization = destination -> (string * string option list) option; |
60 type serialization = destination -> (string * string option list) option; |
61 |
61 |
62 val code_width = Unsynchronized.ref 80; (*FIXME after Pretty module no longer depends on print mode*) |
62 val code_width = Unsynchronized.ref 80; (*FIXME after Pretty module no longer depends on print mode*) |
63 fun code_setmp f = PrintMode.setmp [] (Pretty.setmp_margin (!code_width) f); |
63 fun code_setmp f = PrintMode.setmp [] (Pretty.setmp_margin_CRITICAL (!code_width) f); |
64 fun code_of_pretty p = code_setmp Pretty.string_of p ^ "\n"; |
64 fun code_of_pretty p = code_setmp Pretty.string_of p ^ "\n"; |
65 fun code_writeln p = Pretty.setmp_margin (!code_width) Pretty.writeln p; |
65 fun code_writeln p = Pretty.setmp_margin_CRITICAL (!code_width) Pretty.writeln p; |
66 |
66 |
67 (*FIXME why another code_setmp?*) |
67 (*FIXME why another code_setmp?*) |
68 fun compile f = (code_setmp f Compile; ()); |
68 fun compile f = (code_setmp f Compile; ()); |
69 fun export f = (code_setmp f Export; ()); |
69 fun export f = (code_setmp f Export; ()); |
70 fun file p f = (code_setmp f (File p); ()); |
70 fun file p f = (code_setmp f (File p); ()); |