Lines Matching refs:optind

100    Otherwise, `optind' communicates from one call to the next
104 int optind = 0;
153 `--' can cause `getopt' to return EOF with `optind' != ARGC. */
219 The other is elements [last_nonopt,optind), which contains all
231 int top = optind;
277 first_nonopt += (optind - last_nonopt);
278 last_nonopt = optind;
291 first_nonopt = last_nonopt = optind = 1;
328 updating `optind' and `nextchar' so that the next call to `getopt' can
332 Then `optind' is the index in ARGV of the first ARGV-element
385 if (optind == 0)
397 if (first_nonopt != last_nonopt && last_nonopt != optind)
399 else if (last_nonopt != optind)
400 first_nonopt = optind;
405 while (optind < argc
406 && (argv[optind][0] != '-' || argv[optind][1] == '\0'))
407 optind++;
408 last_nonopt = optind;
416 if (optind != argc && !strcmp (argv[optind], "--"))
418 optind++;
420 if (first_nonopt != last_nonopt && last_nonopt != optind)
423 first_nonopt = optind;
426 optind = argc;
432 if (optind == argc)
437 optind = first_nonopt;
444 if ((argv[optind][0] != '-' || argv[optind][1] == '\0'))
448 optarg = argv[optind++];
455 nextchar = (argv[optind] + 1
456 + (longopts != NULL && argv[optind][1] == '-'));
475 && (argv[optind][1] == '-'
476 || (long_only && (argv[optind][2] || !my_index (optstring, argv[optind][1])))))
521 argv[0], argv[optind]);
523 optind++;
530 optind++;
541 if (argv[optind - 1][1] == '-')
550 argv[0], argv[optind - 1][0], pfound->name);
558 if (optind < argc)
559 optarg = argv[optind++];
564 argv[0], argv[optind - 1]);
584 if (!long_only || argv[optind][1] == '-'
589 if (argv[optind][1] == '-')
596 argv[0], argv[optind][0], nextchar);
599 optind++;
610 /* Increment `optind' when we start to process its last character. */
612 ++optind;
635 optind++;
649 optind++;
651 else if (optind == argc)
666 /* We already incremented `optind' once;
668 optarg = argv[optind++];
706 int this_option_optind = optind ? optind : 1;
750 if (optind < argc)
753 while (optind < argc)
754 printf ("%s ", argv[optind++]);