1
- /* voc 2.00 [2016/12/19 ]. Bootstrapping compiler for address size 8, alignment 8. tspaSF */
1
+ /* voc 2.00 [2016/12/20 ]. Bootstrapping compiler for address size 8, alignment 8. tspaSF */
2
2
3
3
#define SHORTINT INT8
4
4
#define INTEGER INT16
@@ -69,9 +69,6 @@ static void Files_CloseOSFile (Files_File f);
69
69
static void Files_Create (Files_File f );
70
70
export void Files_Delete (CHAR * name , ADDRESS name__len , INT16 * res );
71
71
static void Files_Deregister (CHAR * name , ADDRESS name__len );
72
- export void Files_DumpBuffer (Files_Buffer b , INT16 indent );
73
- export void Files_DumpFile (Files_File f , INT16 indent );
74
- export void Files_DumpRider (Files_Rider r , INT16 indent );
75
72
static void Files_Err (CHAR * s , ADDRESS s__len , Files_File f , INT16 errcode );
76
73
static void Files_Finalize (SYSTEM_PTR o );
77
74
static void Files_FlipBytes (SYSTEM_BYTE * src , ADDRESS src__len , SYSTEM_BYTE * dest , ADDRESS dest__len );
@@ -102,7 +99,6 @@ export void Files_Rename (CHAR *old, ADDRESS old__len, CHAR *new, ADDRESS new__l
102
99
static void Files_ScanPath (INT16 * pos , CHAR * dir , ADDRESS dir__len );
103
100
export void Files_Set (Files_Rider * r , ADDRESS * r__typ , Files_File f , INT32 pos );
104
101
export void Files_SetSearchPath (CHAR * path , ADDRESS path__len );
105
- static void Files_Spaces (INT16 i );
106
102
export void Files_Write (Files_Rider * r , ADDRESS * r__typ , SYSTEM_BYTE x );
107
103
export void Files_WriteBool (Files_Rider * R , ADDRESS * R__typ , BOOLEAN x );
108
104
export void Files_WriteBytes (Files_Rider * r , ADDRESS * r__typ , SYSTEM_BYTE * x , ADDRESS x__len , INT32 n );
@@ -116,132 +112,6 @@ export void Files_WriteString (Files_Rider *R, ADDRESS *R__typ, CHAR *x, ADDRESS
116
112
117
113
#define Files_IdxTrap () __HALT(-1)
118
114
119
- static void Files_Spaces (INT16 i )
120
- {
121
- while (i > 0 ) {
122
- Out_String ((CHAR * )" " , 3 );
123
- i -= 1 ;
124
- }
125
- }
126
-
127
- void Files_DumpFile (Files_File f , INT16 indent )
128
- {
129
- Files_Spaces (indent );
130
- Out_String ((CHAR * )"workName: " , 15 );
131
- Out_String (f -> workName , 101 );
132
- Out_Ln ();
133
- Files_Spaces (indent );
134
- Out_String ((CHAR * )"registerName: " , 15 );
135
- Out_String (f -> registerName , 101 );
136
- Out_Ln ();
137
- Files_Spaces (indent );
138
- Out_String ((CHAR * )"tempFile: " , 15 );
139
- if (f -> tempFile ) {
140
- Out_String ((CHAR * )"TRUE" , 5 );
141
- } else {
142
- Out_String ((CHAR * )"FALSE" , 6 );
143
- }
144
- Out_Ln ();
145
- Files_Spaces (indent );
146
- Out_String ((CHAR * )"identity: " , 15 );
147
- Out_String ((CHAR * )"..." , 4 );
148
- Out_Ln ();
149
- Files_Spaces (indent );
150
- Out_String ((CHAR * )"fd: " , 15 );
151
- Out_Int (f -> fd , 1 );
152
- Out_Ln ();
153
- Files_Spaces (indent );
154
- Out_String ((CHAR * )"len, " , 15 );
155
- Out_Int (f -> len , 1 );
156
- Out_Ln ();
157
- Files_Spaces (indent );
158
- Out_String ((CHAR * )"pos: " , 15 );
159
- Out_Int (f -> pos , 1 );
160
- Out_Ln ();
161
- Files_Spaces (indent );
162
- Out_String ((CHAR * )"bufs: " , 15 );
163
- Out_String ((CHAR * )"..." , 4 );
164
- Out_Ln ();
165
- Files_Spaces (indent );
166
- Out_String ((CHAR * )"swapper: " , 15 );
167
- Out_Int (f -> swapper , 1 );
168
- Out_Ln ();
169
- Files_Spaces (indent );
170
- Out_String ((CHAR * )"state: " , 15 );
171
- Out_Int (f -> state , 1 );
172
- Out_Ln ();
173
- Files_Spaces (indent );
174
- Out_String ((CHAR * )"next: " , 15 );
175
- Out_Hex ((INT32 )(ADDRESS )f -> next , 1 );
176
- Out_Ln ();
177
- }
178
-
179
- void Files_DumpBuffer (Files_Buffer b , INT16 indent )
180
- {
181
- Files_Spaces (indent );
182
- Out_String ((CHAR * )"chg: " , 7 );
183
- if (b -> chg ) {
184
- Out_String ((CHAR * )"TRUE" , 5 );
185
- } else {
186
- Out_String ((CHAR * )"FALSE" , 6 );
187
- }
188
- Out_Ln ();
189
- Files_Spaces (indent );
190
- Out_String ((CHAR * )"org: " , 7 );
191
- Out_Int (b -> org , 1 );
192
- Out_Ln ();
193
- Files_Spaces (indent );
194
- Out_String ((CHAR * )"size: " , 7 );
195
- Out_Int (b -> size , 1 );
196
- Out_Ln ();
197
- Files_Spaces (indent );
198
- Out_String ((CHAR * )"data: " , 7 );
199
- Out_Ln ();
200
- Out_HexDump ((void * )b -> data , 4096 );
201
- Files_Spaces (indent );
202
- Out_String ((CHAR * )"f: " , 7 );
203
- if (b -> f == NIL ) {
204
- Out_String ((CHAR * )"<NIL>" , 6 );
205
- Out_Ln ();
206
- } else {
207
- Out_Ln ();
208
- Files_DumpFile (b -> f , indent + 1 );
209
- }
210
- }
211
-
212
- void Files_DumpRider (Files_Rider r , INT16 indent )
213
- {
214
- Files_Spaces (indent );
215
- Out_String ((CHAR * )"res: " , 9 );
216
- Out_Int (r .res , 1 );
217
- Out_Ln ();
218
- Files_Spaces (indent );
219
- Out_String ((CHAR * )"eof: " , 9 );
220
- if (r .eof ) {
221
- Out_String ((CHAR * )"TRUE" , 5 );
222
- } else {
223
- Out_String ((CHAR * )"FALSE" , 6 );
224
- }
225
- Out_Ln ();
226
- Files_Spaces (indent );
227
- Out_String ((CHAR * )"org: " , 9 );
228
- Out_Int (r .org , 1 );
229
- Out_Ln ();
230
- Files_Spaces (indent );
231
- Out_String ((CHAR * )"offset: " , 9 );
232
- Out_Int (r .offset , 1 );
233
- Out_Ln ();
234
- Files_Spaces (indent );
235
- Out_String ((CHAR * )"buf: " , 9 );
236
- if (r .buf == NIL ) {
237
- Out_String ((CHAR * )"<NIL>" , 6 );
238
- Out_Ln ();
239
- } else {
240
- Out_Ln ();
241
- Files_DumpBuffer (r .buf , indent + 1 );
242
- }
243
- }
244
-
245
115
static void Files_Assert (BOOLEAN truth )
246
116
{
247
117
if (!truth ) {
0 commit comments