Lines Matching refs:beg
562 char const *beg;
563 for (beg = lastnl; beg != lim; beg = memchr (beg, eolbyte, lim - beg), beg++)
588 prline (char const *beg, char const *lim, int sep)
594 nlscan (beg);
601 uintmax_t pos = add_count (totalcc, beg - bufbeg);
611 while ((match_offset = (*execute) (beg, lim - beg, &match_size, 1))
614 char const *b = beg + match_offset;
625 beg = b + match_size;
636 while (lim-beg && (match_offset = (*execute) (beg, lim - beg, &match_size, 1))
639 char const *b = beg + match_offset;
646 fwrite (beg, sizeof (char), match_offset, stdout);
650 beg = b + match_size;
654 fwrite (beg, 1, lim - beg, stdout);
686 prtext (char const *beg, char const *lim, int *nlinesp)
694 prpending (beg);
696 p = beg;
714 while (p < beg)
716 char const *nl = memchr (p, eol, beg - p);
741 prline (beg, lim, ':');
751 grepbuf (char const *beg, char const *lim)
759 p = beg;
809 char *beg;
866 beg = bufbeg + save;
869 if (beg == buflim)
874 oldc = beg[-1];
875 beg[-1] = eol;
878 beg[-1] = oldc;
879 if (lim == beg)
880 lim = beg - residue;
881 beg -= residue;
884 if (beg < lim)
887 nlines += grepbuf (beg, lim);
896 next data. Make beg point to their begin. */
898 beg = lim;
899 while (i < out_before && beg > bufbeg && beg != lastout)
903 --beg;
904 while (beg[-1] != eol);
908 if (beg != lastout)
912 save = residue + lim - beg;
916 nlscan (beg);