Lines Matching defs:tos

286 string_type *tos;
322 if (tos < stack)
324 if (tos >= stack + STACK)
395 if (tos->write_idx)
396 tos->write_idx--;
403 while ((isspace ((unsigned char) at (tos, tos->write_idx - 1))
404 || at (tos, tos->write_idx - 1) == '\n')
405 && tos->write_idx > 0)
406 tos->write_idx--;
423 tos++;
425 init_string (tos);
427 cattext (tos, *((char **) pc));
493 (long) (tos - stack));
521 || find (tos, "PARAMS") || find (tos, "PROTO") || !find (tos, "("))
523 catstr (&out, tos);
528 for (openp = 0; at (tos, openp) != '(' && at (tos, openp); openp++)
534 while (fname && isspace ((unsigned char) at (tos, fname)))
537 && !isspace ((unsigned char) at (tos,fname))
538 && at (tos,fname) != '*')
547 if (!isspace ((unsigned char) at (tos, len - 1)))
551 catchar (&out, at (tos, idx));
559 if (!isspace ((unsigned char) at (tos, len - 1)))
563 catchar (&out, at (tos, idx));
567 for (idx = openp; at (tos, idx) && at (tos, idx) != ';'; idx++)
568 catchar (&out, at (tos, idx));
572 overwrite_string (tos, &out);
587 while (at (tos, idx))
589 if (at (tos, idx) == '{' && at (tos, idx + 1) == '*')
594 else if (at (tos, idx) == '*' && at (tos, idx + 1) == '}')
601 catchar (&out, at (tos, idx));
606 overwrite_string (tos, &out);
611 /* Mod tos so that only lines with leading dots remain */
619 while (at (tos, idx))
622 if (at (tos, idx) == '.')
628 while ((c = at (tos, idx)) && c != '\n')
630 if (c == '{' && at (tos, idx + 1) == '*')
635 else if (c == '*' && at (tos, idx + 1) == '}')
652 idx = skip_past_newline_1 (tos, idx);
656 overwrite_string (tos, &out);
660 /* Find lines starting with . and | and put example around them on tos */
670 while (at (tos, idx))
672 if (at (tos, idx) == '\n'
673 && (at (tos, idx +1 ) == '.'
674 || at (tos, idx + 1) == '|'))
681 while (at (tos, idx) && at (tos, idx) != '\n')
687 if (at (tos, idx) == '{')
689 else if (at (tos, idx) == '}')
694 if (at (tos, idx) == '{')
696 else if (!islower ((unsigned char) at (tos, idx)))
699 else if (at (tos, idx) == '@'
700 && islower ((unsigned char) at (tos, idx + 1)))
704 else if (at (tos, idx) == '{' && at (tos, idx + 1) == '*')
710 else if (at (tos, idx) == '*' && at (tos, idx + 1) == '}')
716 else if (at (tos, idx) == '{'
717 || at (tos, idx) == '}')
722 catchar (&out, at (tos, idx));
727 while (at (tos, idx) == '\n'
728 && ((at (tos, idx + 1) == '.')
729 || (at (tos, idx + 1) == '|')))
735 catchar (&out, at (tos, idx));
740 overwrite_string (tos, &out);
756 while (at (tos, idx))
758 if (at (tos, idx) == '@'
759 && at (tos, idx + 1) == '*')
764 else if (at (tos, idx) == '\n'
765 && at (tos, idx + 1) == 'o'
766 && isspace ((unsigned char) at (tos, idx + 2)))
779 catchar (&out, at (tos, idx));
780 if (on && at (tos, idx) == '\n'
781 && at (tos, idx + 1) == '\n'
782 && at (tos, idx + 2) != 'o')
796 delete_string (tos);
797 *tos = out;
809 while (at (tos, idx))
811 if (at (tos, idx) == '<'
812 && at (tos, idx + 1) == '<'
813 && !isspace ((unsigned char) at (tos, idx + 2)))
818 while (at (tos, idx)
819 && at (tos, idx) != '>' )
821 catchar (&out, at (tos, idx));
830 catchar (&out, at (tos, idx));
834 delete_string (tos);
835 *tos = out;
903 tos++;
905 init_string (tos);
906 idx = copy_past_newline (ptr, idx, tos);
925 while (at (tos, idx) == '\n')
933 if (at (tos, idx) == '.')
937 while (at (tos, idx))
945 while (idx && isspace ((unsigned char) at (tos, idx)))
955 if (at (tos, c) == '\n'
956 && at (tos, c + 1) == '\n'
957 && at (tos, c + 2) == '.')
962 else if (at (tos, c) == '.' && sl)
967 else if (at (tos, c) == '\n'
968 && at (tos, c + 1) == '\n'
975 catchar (&out, at (tos, c));
976 if (at (tos, c) == '\n')
995 delete_string (tos);
996 *tos = out;
1008 while (at (tos, idx))
1010 switch (at (tos, idx))
1015 if (tab && at (tos, idx))
1037 catchar (&out, at (tos, idx));
1046 delete_string (tos);
1047 *tos = out;
1054 tos++;
1056 init_string (tos);
1062 idx = copy_past_newline (ptr, idx, tos);
1072 t = tos[0];
1073 tos[0] = tos[-1];
1074 tos[-1] = t;
1081 tos++;
1083 init_string (tos);
1084 catstr (tos, tos - 1);
1091 tos--;
1093 delete_string (tos + 1);
1108 tos--;
1110 catstr (tos, tos + 1);
1111 delete_string (tos + 1);
1136 catstr (tos - 1, tos);
1138 delete_string (tos);
1139 tos--;
1284 tos = stack;
1495 write_buffer (tos, stdout);
1497 write_buffer (tos, stderr);
1501 tos--;
1555 tos = stack + 1;
1635 if (tos != stack)
1638 (long) (tos - stack));