Lines Matching defs:tos

127 string_type *tos;
319 if (tos < stack)
321 if (tos >= stack + STACK)
354 if (tos->write_idx)
355 tos->write_idx--;
362 while ((isspace ((unsigned char) at (tos, tos->write_idx - 1))
363 || at (tos, tos->write_idx - 1) == '\n')
364 && tos->write_idx > 0)
365 tos->write_idx--;
382 tos++;
384 init_string (tos);
386 cattext (tos, pc->s);
450 (long) (tos - stack));
478 || find (tos, "PARAMS") || find (tos, "PROTO") || !find (tos, "("))
480 catstr (&out, tos);
485 for (openp = 0; at (tos, openp) != '(' && at (tos, openp); openp++)
491 while (fname && isspace ((unsigned char) at (tos, fname)))
494 && !isspace ((unsigned char) at (tos,fname))
495 && at (tos,fname) != '*')
504 if (!isspace ((unsigned char) at (tos, len - 1)))
508 catchar (&out, at (tos, idx));
516 if (!isspace ((unsigned char) at (tos, len - 1)))
520 catchar (&out, at (tos, idx));
524 for (idx = openp; at (tos, idx) && at (tos, idx) != ';'; idx++)
525 catchar (&out, at (tos, idx));
529 overwrite_string (tos, &out);
544 while (at (tos, idx))
546 if (at (tos, idx) == '{' && at (tos, idx + 1) == '*')
551 else if (at (tos, idx) == '*' && at (tos, idx + 1) == '}')
558 catchar (&out, at (tos, idx));
563 overwrite_string (tos, &out);
568 /* Mod tos so that only lines with leading dots remain */
576 while (at (tos, idx))
579 if (at (tos, idx) == '.')
585 while ((c = at (tos, idx)) && c != '\n')
587 if (c == '{' && at (tos, idx + 1) == '*')
592 else if (c == '*' && at (tos, idx + 1) == '}')
609 idx = skip_past_newline_1 (tos, idx);
613 overwrite_string (tos, &out);
617 /* Find lines starting with . and | and put example around them on tos */
627 while (at (tos, idx))
629 if (at (tos, idx) == '\n'
630 && (at (tos, idx +1 ) == '.'
631 || at (tos, idx + 1) == '|'))
638 while (at (tos, idx) && at (tos, idx) != '\n')
644 if (at (tos, idx) == '{')
646 else if (at (tos, idx) == '}')
651 if (at (tos, idx) == '{')
653 else if (!islower ((unsigned char) at (tos, idx)))
656 else if (at (tos, idx) == '@'
657 && islower ((unsigned char) at (tos, idx + 1)))
661 else if (at (tos, idx) == '{' && at (tos, idx + 1) == '*')
667 else if (at (tos, idx) == '*' && at (tos, idx + 1) == '}')
673 else if (at (tos, idx) == '{'
674 || at (tos, idx) == '}')
679 catchar (&out, at (tos, idx));
684 while (at (tos, idx) == '\n'
685 && ((at (tos, idx + 1) == '.')
686 || (at (tos, idx + 1) == '|')))
692 catchar (&out, at (tos, idx));
697 overwrite_string (tos, &out);
713 while (at (tos, idx))
715 if (at (tos, idx) == '@'
716 && at (tos, idx + 1) == '*')
721 else if (at (tos, idx) == '\n'
722 && at (tos, idx + 1) == 'o'
723 && isspace ((unsigned char) at (tos, idx + 2)))
736 catchar (&out, at (tos, idx));
737 if (on && at (tos, idx) == '\n'
738 && at (tos, idx + 1) == '\n'
739 && at (tos, idx + 2) != 'o')
753 delete_string (tos);
754 *tos = out;
766 while (at (tos, idx))
768 if (at (tos, idx) == '<'
769 && at (tos, idx + 1) == '<'
770 && !isspace ((unsigned char) at (tos, idx + 2)))
775 while (at (tos, idx)
776 && at (tos, idx) != '>' )
778 catchar (&out, at (tos, idx));
787 catchar (&out, at (tos, idx));
791 delete_string (tos);
792 *tos = out;
855 tos++;
857 init_string (tos);
858 idx = copy_past_newline (ptr, idx, tos);
877 while (at (tos, idx) == '\n')
885 if (at (tos, idx) == '.')
889 while (at (tos, idx))
897 while (idx && isspace ((unsigned char) at (tos, idx)))
907 if (at (tos, c) == '\n'
908 && at (tos, c + 1) == '\n'
909 && at (tos, c + 2) == '.')
914 else if (at (tos, c) == '.' && sl)
919 else if (at (tos, c) == '\n'
920 && at (tos, c + 1) == '\n'
927 catchar (&out, at (tos, c));
928 if (at (tos, c) == '\n')
947 delete_string (tos);
948 *tos = out;
960 while (at (tos, idx))
962 switch (at (tos, idx))
967 if (tab && at (tos, idx))
989 catchar (&out, at (tos, idx));
998 delete_string (tos);
999 *tos = out;
1006 tos++;
1008 init_string (tos);
1014 idx = copy_past_newline (ptr, idx, tos);
1024 t = tos[0];
1025 tos[0] = tos[-1];
1026 tos[-1] = t;
1033 tos++;
1035 init_string (tos);
1036 catstr (tos, tos - 1);
1043 tos--;
1045 delete_string (tos + 1);
1060 tos--;
1062 catstr (tos, tos + 1);
1063 delete_string (tos + 1);
1088 catstr (tos - 1, tos);
1090 delete_string (tos);
1091 tos--;
1230 tos = stack;
1424 write_buffer (tos, stdout);
1426 write_buffer (tos, stderr);
1430 tos--;
1480 tos = stack + 1;
1560 if (tos != stack)
1563 (long) (tos - stack));