getopt.c File Reference

#include <stdio.h>
#include "getopt.h"
#include <strings.h>

Include dependency graph for getopt.c:

Go to the source code of this file.

Defines

#define GETOPT_INTERFACE_VERSION   2
#define _(msgid)   (msgid)
#define SWAP_FLAGS(ch1, ch2)
#define NONOPTION_P   (argv[optind][0] != '-' || argv[optind][1] == '\0')

Enumerations

enum  { REQUIRE_ORDER, PERMUTE, RETURN_IN_ORDER }

Functions

char * getenv ()
int _getopt_internal (int argc, char *const *argv, const char *optstring, const struct option *longopts, int *longind, int long_only)
int getopt (int argc, char *const *argv, const char *optstring)

Variables

char * optarg
int optind = 1
int __getopt_initialized
int opterr = 1
int optopt = '?'


Define Documentation

#define _ ( msgid   )     (msgid)

Definition at line 89 of file getopt.c.

#define GETOPT_INTERFACE_VERSION   2

Definition at line 54 of file getopt.c.

#define NONOPTION_P   (argv[optind][0] != '-' || argv[optind][1] == '\0')

#define SWAP_FLAGS ( ch1,
ch2   ) 

Definition at line 287 of file getopt.c.


Enumeration Type Documentation

anonymous enum

Enumerator:
REQUIRE_ORDER 
PERMUTE 
RETURN_IN_ORDER 

Definition at line 190 of file getopt.c.


Function Documentation

int _getopt_internal ( int  argc,
char *const *  argv,
const char *  optstring,
const struct option longopts,
int *  longind,
int  long_only 
)

Definition at line 511 of file getopt.c.

References __getopt_initialized, option::name, NONOPTION_P, optarg, opterr, optind, PERMUTE, and REQUIRE_ORDER.

char* getenv (  ) 

int getopt ( int  argc,
char *const *  argv,
const char *  optstring 
)

Definition at line 1171 of file getopt.c.

References _getopt_internal().

Here is the call graph for this function:


Variable Documentation

int __getopt_initialized

Definition at line 139 of file getopt.c.

char* optarg

Definition at line 118 of file getopt.c.

int opterr = 1

Definition at line 153 of file getopt.c.

int optind = 1

Definition at line 133 of file getopt.c.

int optopt = '?'

Definition at line 159 of file getopt.c.


Generated on Mon Jul 2 19:10:23 2007 for CanFestival by  doxygen 1.5.1