[Patches] [Patch #102170] move getopt() to Py_GetOpt() and use it unconditionally

noreply@sourceforge.net noreply@sourceforge.net
Mon, 30 Oct 2000 10:08:49 -0800


Patch #102170 has been updated. 

Project: python
Category: core (C code)
Status: Open
Summary: move getopt() to Py_GetOpt() and use it unconditionally

Follow-Ups:

Date: 2000-Oct-30 09:48
By: twouters

Comment:
This patch attempts to do what Tim suggested in the python-dev thread about getopt()'s prototype and the difficulties of it. the 'getopt' implementation as provided in Python/getopt.c is renamed to Py_GetOpt(), the exported variables 'opterr', 'optind' and 'optarg' are prefixed with Py_, and all use in the Python sourcetree is adjusted.

The patch is missing the 'pygetopt.h' include file, though :P I'll resubmit a proper patch later. 

There are a couple of issues still open: the name of the getopt.c file, its use of 'fprintf(stderr, ... )', its license, documentation (which this patch lacks) and whether this Py_GetOpt should be an officially exported API at all.


-------------------------------------------------------

Date: 2000-Oct-30 10:08
By: twouters

Comment:
New patch, includes pygetopt.h by hack. (not sure if it patches cleanly, but it's not that exciting a file anyway :) Assigned to.... (spin wheel... Guido. no. spin wheel... Barry. no. spin wheel... Moshe. dang. spin wheel... *nudge*. Ah, finally,) Tim.


-------------------------------------------------------

-------------------------------------------------------
For more info, visit:

http://sourceforge.net/patch/?func=detailpatch&patch_id=102170&group_id=5470