Lines Matching refs:f
5 void shinit_wcstring(struct fake_file_t *f, const wchar_t* wcs) { in shinit_wcstring() argument
6 f->rstart = wcs; in shinit_wcstring()
7 f->rpos = wcs; in shinit_wcstring()
8 f->rend = wcs + wcslen(wcs); in shinit_wcstring()
9 f->extra_eof = 0; in shinit_wcstring()
12 int shgetc(struct fake_file_t *f) { in shgetc() argument
13 if (f->rpos >= f->rend) { in shgetc()
14 f->extra_eof ++; in shgetc()
17 wchar_t wc = *f->rpos++; in shgetc()
22 void shunget(struct fake_file_t *f) { in shunget() argument
23 if (f->extra_eof) { in shunget()
24 f->extra_eof--; in shunget()
25 } else if (f->rpos > f->rstart) { in shunget()
26 f->rpos--; in shunget()
30 void shlim(struct fake_file_t *f, off_t lim) { in shlim() argument
31 int off = f->rpos - f->rstart; in shlim()
33 f->rpos = f->rstart + lim; in shlim()
37 off_t shcnt(struct fake_file_t *f) { in shcnt() argument
38 return (off_t)(f->rpos - f->rstart); in shcnt()