Lines Matching refs:to
189 s_append(string *to, char *from) in s_append() argument
191 if (to == NULL) in s_append()
192 to = s_new(); in s_append()
194 return (to); in s_append()
196 s_putc(to, (int)(unsigned int)*from); in s_append()
197 s_terminate(to); in s_append()
198 return (to); in s_append()
214 s_seq_read(FILE *fp, string *to, int lineortoken) in s_seq_read() argument
227 if (to != NULL) in s_seq_read()
228 s_terminate(to); in s_seq_read()
247 if (to == NULL) in s_seq_read()
248 to = s_new(); in s_seq_read()
256 s_putc(to, (int)(unsigned int)'\\'); in s_seq_read()
257 s_putc(to, c); in s_seq_read()
264 s_terminate(to); in s_seq_read()
265 return (to); in s_seq_read()
269 s_terminate(to); in s_seq_read()
270 return (to); in s_seq_read()
274 s_putc(to, c); in s_seq_read()
287 string *to = s_new(); in s_tok() local
289 s_putc(to, (int)(unsigned int)*from->ptr); in s_tok()
292 s_terminate(to); in s_tok()
293 s_restart(to); in s_tok()
296 return (to); in s_tok()
300 string *to = s_clone(from); in s_tok() local
303 return (to); in s_tok()
317 s_read_line(FILE *fp, string *to) in s_read_line() argument
322 s_terminate(to); in s_read_line()
333 s_terminate(to); in s_read_line()
334 return (to->ptr - len); in s_read_line()
336 s_putc(to, (int)(unsigned int)'\n'); in s_read_line()
337 s_terminate(to); in s_read_line()
338 return (to->ptr - len); in s_read_line()
340 s_putc(to, c); in s_read_line()
351 s_read_to_eof(FILE *fp, string *to) in s_read_to_eof() argument
356 s_terminate(to); in s_read_to_eof()
362 have = to->end - to->ptr; in s_read_to_eof()
364 s_simplegrow(to, (size_t)4096); in s_read_to_eof()
367 have = to->end - to->ptr; in s_read_to_eof()
368 got = fread(to->ptr, (size_t)1, have, fp); in s_read_to_eof()
372 to->ptr += got; in s_read_to_eof()
376 s_terminate(to); in s_read_to_eof()
377 return (to->ptr - to->base); in s_read_to_eof()
388 s_parse(string *from, string *to) in s_parse() argument
394 if (to == NULL) in s_parse()
395 to = s_new(); in s_parse()
399 s_putc(to, (int)(unsigned int)*from->ptr); in s_parse()
405 s_putc(to, (int)(unsigned int)*from->ptr); in s_parse()
410 s_putc(to, (int)(unsigned int)*from->ptr); in s_parse()
412 s_terminate(to); in s_parse()
414 return (to); in s_parse()