• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /macosx-10.9.5/zsh-60/zsh/Src/Zle/

Lines Matching +defs:first +defs:line +defs:prefix

47     int pre;                    /* longest prefix length (before description) */
54 int gprew; /* prefix screen width for group display */
67 int kind; /* 0: not in a group, 1: the first, 2: other */
184 /* Calculate longest prefix and suffix and count the strings with
624 * max prefix length (cd_state.pre) +
874 /* used while parsing a command line */
875 char *set; /* set name prefix (<name>-), shared */
892 int active; /* still allowed on command line */
917 int active; /* still allowed on command line */
1331 /* If it's a long option skip over the first `-'. */
1621 * Get the option used in a word from the line, if any.
1624 * "line" is the word we are scanning.
1632 ca_get_opt(Cadef d, char *line, int full, char **end)
1639 if (p->active && !strcmp(p->name, line)) {
1641 *end = line + strlen(line);
1647 /* The string from the line probably only begins with an option. */
1650 !strcmp(p->name, line) : strpfx(p->name, line))) {
1656 line[l] == '=')
1659 *end = line + l;
1670 ca_get_sopt(Cadef d, char *line, char **end, LinkList *lp)
1673 char pre = *line++;
1677 for (p = NULL; *line; line++) {
1678 if ((p = d->single[STOUC(*line)]) && p->active &&
1686 line++;
1688 *line == '=')
1689 line++;
1690 *end = line;
1701 *end = line;
1798 /* State when parsing a command line. */
1840 ca_opt_arg(Caopt opt, char *line)
1847 if (*line == '\\' || *line == '\'' || *line == '"')
1848 line++;
1849 if (!*o || *o != *line)
1852 line++;
1854 if (*line && (opt->type == CAO_EQUAL || opt->type == CAO_OEQUAL)) {
1855 if (*line == '\\')
1856 line++;
1857 if (*line == '=')
1858 line++;
1860 return ztrdup(line);
1863 /* Parse a command line. */
1866 ca_parse_line(Cadef d, int multi, int first)
1871 char *line, *oline, *pe, **argxor = NULL;
1881 if (first && ca_alloced) {
1928 /* Loop over the words from the line. */
1930 for (line = compwords[1], cur = 2, state.curopt = NULL, state.def = NULL;
1931 line; line = compwords[cur++]) {
1936 oline = line;
1941 * between command line values that can be expanded and those
1948 line = dupstring(line);
1951 parse_subst_string(line);
1954 remnulargs(line);
1955 untokenize(line);
1958 ((d->flags & CDF_SEP) && cur != compcurrent && !strcmp(line, "--"))) {
1975 if (state.def->end && pattry(endpat, line)) {
2005 state.opt = (line[0] ? (line[1] ? 2 : 1) : 0);
2013 if (state.opt == 2 && (state.curopt = ca_get_opt(d, line, 0, &pe)) &&
2024 doff = pe - line;
2061 ((state.curopt = ca_get_sopt(d, line, &pe, &sopts)) ||
2078 doff = pe - line;
2083 for (p = line + 1; p < pe; p++) {
2105 ca_opt_arg(state.curopt, line));
2111 } else if (multi && (*line == '-' || *line == '+') && cur != compcurrent
2116 && (!napat || !pattry(napat, line))
2120 else if (state.arg && (!napat || !pattry(napat, line))) {
2131 if (!d->args && !d->rest && *line && *line != '-' && *line != '+') {
2158 (!multi || !*line ||
2159 *line == '-' || *line == '+'));
2164 for (; line; line = compwords[cur++])
2165 zaddlinknode(state.args, ztrdup(line));
2173 zaddlinknode(state.args, ztrdup(line));
2202 for (; line; line = compwords[cur++])
2203 zaddlinknode(l, ztrdup(line));
2237 ca_laststate.opt = (!arglast || !multi || !*line ||
2238 *line == '-' || *line == '+');
2457 int cap = ca_parsed, multi, first = 1, use, ret = 0;
2474 use = !ca_parse_line(def, multi, first);
2505 first = 0;
2517 * things _arguments has to execute at this place on the line (the
2620 * complete to `--prefix=/...'. The options name isn't fully typed
2688 /* This gets two parameter names as arguments. The first is set to
2691 * the line and their arguments. I.e. the stuff _arguments returns
2692 * to its caller in the `line' and `opt_args' parameters. */
3451 /* This returns the description string (first argument to _values)
3457 * and returns the description and action of its first argument, if
3458 * any. The rest (prefix matching) is in _values. Return non-zero
3491 comp_quote(char *str, int prefix)
3496 if ((x = (prefix && *str == '=')))
3997 * prefix or suffix from the command line.
4042 * the other components, and the prefix and suffix.
4123 * We take account of equivalences between the word and line, too.
4182 if (m->line->tp == CPAT_EQUIV &&
4199 if (PATMATCHRANGE(m->line->u.str, addc, &ind, &mt)) {
4274 * if *add is ] and ] is also the first
4367 if (pattern_match(m->line, tmp, NULL, NULL)) {
4381 stopp = m->line;
4401 stopp = m->line;