Lines Matching refs:os
16 fun writeInt32 os i =
21 (BinIO.output1 (os, w32tow8 w);
22 BinIO.output1 (os, w32tow8 (Word32.>> (w, 0w8)));
23 BinIO.output1 (os, w32tow8 (Word32.>> (w, 0w16)));
24 BinIO.output1 (os, w32tow8 (Word32.>> (w, 0w24))))
39 fun writeString os s =
40 (writeInt32 os (String.size s);
41 BinIO.output (os, Byte.stringToBytes s));
48 fun writeList write os l =
51 BinIO.output1 (os, 0w0)
53 (BinIO.output1 (os, 0w1);
54 write os e;
55 writeList write os t)
75 fun writeComponent os Str =
76 BinIO.output1 (os, 0w0)
77 | writeComponent os (Exc s) =
78 (BinIO.output1 (os, 0w1);
79 writeString os s)
80 | writeComponent os (Typ s) =
81 (BinIO.output1 (os, 0w2);
82 writeString os s)
83 | writeComponent os (Val s) =
84 (BinIO.output1 (os, 0w3);
85 writeString os s)
86 | writeComponent os (Con s) =
87 (BinIO.output1 (os, 0w4);
88 writeString os s)
89 | writeComponent os (Term (s, NONE)) =
90 (BinIO.output1 (os, 0w5);
91 writeString os s)
92 | writeComponent os (Term (s1, SOME s2)) =
93 (BinIO.output1 (os, 0w6);
94 writeString os s1;
95 writeString os s2);
119 fun writeEntry os (e:entry) =
120 (writeComponent os (#comp e);
121 writeString os (#file e);
122 writeInt32 os (#line e));
139 fun writeTable os Empty =
140 BinIO.output1 (os, 0w0)
141 | writeTable os (Node (s, el, t1, t2)) =
142 (BinIO.output1 (os, 0w1);
143 writeString os s;
144 writeList writeEntry os el;
145 writeTable os t1;
146 writeTable os t2);
168 let val os = BinIO.openOut filename in
169 writeTable os db;
170 BinIO.closeOut os