Lines Matching refs:idx

175 addr (buffer, idx)
177 unsigned int idx;
179 return buffer->ptr + idx;
250 skip_white_and_stars (src, idx)
252 unsigned int idx;
255 while ((c = at (src, idx)),
260 && at (src, idx +1) != '/'
261 && at (src, idx -1) != '\n'))
262 idx++;
263 return idx;
271 unsigned int idx = 0; /* Pos in input buffer */
424 unsigned int idx = 0;
426 while (at (src, idx))
429 if (at (src, idx) == '\n'
430 && at (src, idx + 1) == '/'
431 && at (src, idx + 2) == '*')
433 idx += 3;
435 idx = skip_white_and_stars (src, idx);
438 if (at (src, idx) == '.')
439 idx++;
443 while (at (src, idx))
445 if (at (src, idx) == '\n')
448 if (at (src, idx + 1) == '\n')
451 idx++;
452 idx = skip_white_and_stars (src, idx);
454 else if (at (src, idx) == '*' && at (src, idx + 1) == '/')
456 idx += 2;
462 catchar (dst, at (src, idx));
463 idx++;
468 idx++;
493 unsigned int idx;
531 for (idx = 0; idx < len; idx++)
532 catchar (&out, at (tos, idx));
543 for (idx = fname; idx < len; idx++)
544 catchar (&out, at (tos, idx));
548 for (idx = openp; at (tos, idx) && at (tos, idx) != ';'; idx++)
549 catchar (&out, at (tos, idx));
564 unsigned int idx = 0;
568 while (at (tos, idx))
570 if (at (tos, idx) == '{' && at (tos, idx + 1) == '*')
573 idx += 2;
575 else if (at (tos, idx) == '*' && at (tos, idx + 1) == '}')
578 idx += 2;
582 catchar (&out, at (tos, idx));
583 idx++;
596 unsigned int idx = 0;
600 while (at (tos, idx))
602 if (at (tos, idx) == '\n' && at (tos, idx + 1) == '.')
605 idx += 2;
607 while ((c = at (tos, idx)) && c != '\n')
609 if (c == '{' && at (tos, idx + 1) == '*')
612 idx += 2;
614 else if (c == '*' && at (tos, idx + 1) == '}')
617 idx += 2;
622 idx++;
629 idx++;
642 unsigned int idx = 0;
647 while (at (tos, idx))
649 if (at (tos, idx) == '\n'
650 && (at (tos, idx +1 ) == '.'
651 || at (tos, idx + 1) == '|'))
656 idx += 2;
658 while (at (tos, idx) && at (tos, idx) != '\n')
664 if (at (tos, idx) == '{')
666 else if (at (tos, idx) == '}')
671 if (at (tos, idx) == '{')
673 else if (!islower ((unsigned char) at (tos, idx)))
676 else if (at (tos, idx) == '@'
677 && islower ((unsigned char) at (tos, idx + 1)))
681 else if (at (tos, idx) == '{' && at (tos, idx + 1) == '*')
684 idx += 2;
687 else if (at (tos, idx) == '*' && at (tos, idx + 1) == '}')
690 idx += 2;
693 else if (at (tos, idx) == '{'
694 || at (tos, idx) == '}')
699 catchar (&out, at (tos, idx));
700 idx++;
704 while (at (tos, idx) == '\n'
705 && ((at (tos, idx + 1) == '.')
706 || (at (tos, idx + 1) == '|')))
712 catchar (&out, at (tos, idx));
713 idx++;
728 unsigned int idx = 0;
733 while (at (tos, idx))
735 if (at (tos, idx) == '@'
736 && at (tos, idx + 1) == '*')
739 idx += 2;
741 else if (at (tos, idx) == '\n'
742 && at (tos, idx + 1) == 'o'
743 && isspace ((unsigned char) at (tos, idx + 2)))
752 idx += 3;
756 catchar (&out, at (tos, idx));
757 if (on && at (tos, idx) == '\n'
758 && at (tos, idx + 1) == '\n'
759 && at (tos, idx + 2) != 'o')
764 idx++;
783 unsigned int idx = 0;
786 while (at (tos, idx))
788 if (at (tos, idx) == '<'
789 && at (tos, idx + 1) == '<'
790 && !isspace ((unsigned char) at (tos, idx + 2)))
793 idx += 2;
795 while (at (tos, idx)
796 && at (tos, idx) != '>' )
798 catchar (&out, at (tos, idx));
799 idx++;
803 idx += 2;
807 catchar (&out, at (tos, idx));
808 idx++;
820 iscommand (ptr, idx)
822 unsigned int idx;
825 while (at (ptr, idx))
827 if (isupper ((unsigned char) at (ptr, idx))
828 || at (ptr, idx) == ' ' || at (ptr, idx) == '_')
831 idx++;
833 else if (at (ptr, idx) == '\n')
846 copy_past_newline (ptr, idx, dst)
848 unsigned int idx;
853 while (at (ptr, idx) && at (ptr, idx) != '\n')
855 if (at (ptr, idx) == '\t')
865 catchar (dst, at (ptr, idx));
868 idx++;
871 catchar (dst, at (ptr, idx));
872 idx++;
873 return idx;
883 idx = copy_past_newline (ptr, idx, tos);
895 int idx = 0;
902 while (at (tos, idx) == '\n')
904 idx++;
906 c = idx;
910 if (at (tos, idx) == '.')
914 while (at (tos, idx))
916 idx++;
920 idx--;
922 while (idx && isspace ((unsigned char) at (tos, idx)))
923 idx--;
924 idx++;
930 while (c < idx)
982 int idx = 0;
985 while (at (tos, idx))
987 switch (at (tos, idx))
991 idx++;
992 if (tab && at (tos, idx))
1002 idx++;
1009 idx++;
1014 catchar (&out, at (tos, idx));
1017 idx++;
1035 while (at (ptr, idx))
1037 if (iscommand (ptr, idx))
1039 idx = copy_past_newline (ptr, idx, tos);
1094 while (at (ptr, idx)
1095 && at (ptr, idx) != '\n')
1096 idx++;
1097 idx++;
1129 int idx;
1181 for (idx = 0; idx < length; idx++)
1183 if (src[idx] == '\\')
1184 switch (src[idx + 1])
1188 idx++;
1192 *dst++ = src[idx + 1];
1193 idx++;
1200 *dst++ = src[idx];
1233 while (at (ptr, idx))
1236 if (iscommand (ptr, idx))
1241 (void) nextword (addr (ptr, idx), &next);