Lines Matching defs:byte_idx

212   int byte_idx, end_idx, remain_len;
218 for (byte_idx = pstr->valid_len; byte_idx < end_idx;)
223 remain_len = end_idx - byte_idx;
232 ch = pstr->raw_mbs [pstr->raw_mbs_idx + byte_idx + i];
233 buf[i] = pstr->mbs[byte_idx + i] = pstr->trans[ch];
238 p = (const char *) pstr->raw_mbs + pstr->raw_mbs_idx + byte_idx;
245 wc = (wchar_t) pstr->raw_mbs[pstr->raw_mbs_idx + byte_idx];
258 pstr->wcs[byte_idx++] = wc;
260 for (remain_len = byte_idx + mbclen - 1; byte_idx < remain_len ;)
261 pstr->wcs[byte_idx++] = WEOF;
263 pstr->valid_len = byte_idx;
264 pstr->valid_raw_len = byte_idx;
275 int src_idx, byte_idx, end_idx, remain_len;
284 byte_idx = pstr->valid_len;
291 while (byte_idx < end_idx)
295 if (isascii (pstr->raw_mbs[pstr->raw_mbs_idx + byte_idx])
299 pstr->mbs[byte_idx]
300 = toupper (pstr->raw_mbs[pstr->raw_mbs_idx + byte_idx]);
303 pstr->wcs[byte_idx] = (wchar_t) pstr->mbs[byte_idx];
304 ++byte_idx;
308 remain_len = end_idx - byte_idx;
312 + byte_idx), remain_len, &pstr->cur_state);
323 memcpy (pstr->mbs + byte_idx, buf, mbclen);
326 src_idx = byte_idx;
331 memcpy (pstr->mbs + byte_idx,
332 pstr->raw_mbs + pstr->raw_mbs_idx + byte_idx, mbclen);
333 pstr->wcs[byte_idx++] = wcu;
335 for (remain_len = byte_idx + mbclen - 1; byte_idx < remain_len ;)
336 pstr->wcs[byte_idx++] = WEOF;
343 int ch = pstr->raw_mbs[pstr->raw_mbs_idx + byte_idx];
344 pstr->mbs[byte_idx] = ch;
346 pstr->wcs[byte_idx++] = (wchar_t) ch;
357 pstr->valid_len = byte_idx;
358 pstr->valid_raw_len = byte_idx;
362 for (src_idx = pstr->valid_raw_len; byte_idx < end_idx;)
367 remain_len = end_idx - byte_idx;
393 memcpy (pstr->mbs + byte_idx, buf, mbclen);
398 if (byte_idx + mbcdlen > pstr->bufs_len)
413 for (i = 0; i < (size_t) byte_idx; ++i)
418 memcpy (pstr->mbs + byte_idx, buf, mbcdlen);
419 pstr->wcs[byte_idx] = wcu;
420 pstr->offsets[byte_idx] = src_idx;
423 pstr->offsets[byte_idx + i]
425 pstr->wcs[byte_idx + i] = WEOF;
432 byte_idx += mbcdlen;
437 memcpy (pstr->mbs + byte_idx, p, mbclen);
440 memcpy (pstr->mbs + byte_idx, p, mbclen);
446 pstr->offsets[byte_idx + i] = src_idx + i;
450 pstr->wcs[byte_idx++] = wcu;
452 for (remain_len = byte_idx + mbclen - 1; byte_idx < remain_len ;)
453 pstr->wcs[byte_idx++] = WEOF;
463 pstr->mbs[byte_idx] = ch;
466 pstr->offsets[byte_idx] = src_idx;
470 pstr->wcs[byte_idx++] = (wchar_t) ch;
481 pstr->valid_len = byte_idx;