Staging
v0.5.1
https://github.com/python/cpython
Revision 1ff0c6c9f81419082973d0b796e6c2146dacf0b7 authored by Ezio Melotti on 03 March 2010, 20:12:28 UTC, committed by Ezio Melotti on 03 March 2010, 20:12:28 UTC
svn+ssh://pythondev@svn.python.org/python/branches/py3k

........
  r78632 | ezio.melotti | 2010-03-03 22:10:45 +0200 (Wed, 03 Mar 2010) | 1 line

  Add the argparse module and Steven as its maintainer.
........
1 parent 8d63db8
Raw File
Tip revision: 1ff0c6c9f81419082973d0b796e6c2146dacf0b7 authored by Ezio Melotti on 03 March 2010, 20:12:28 UTC
Merged revisions 78632 via svnmerge from
Tip revision: 1ff0c6c
generrmap.c
#include <stdio.h>
#include <errno.h>

/* Extract the mapping of Win32 error codes to errno */

int main()
{
	int i;
	printf("/* Generated file. Do not edit. */\n");
	printf("int winerror_to_errno(int winerror)\n");
	printf("{\n\tswitch(winerror) {\n");
	for(i=1; i < 65000; i++) {
		_dosmaperr(i);
		if (errno == EINVAL)
			continue;
		printf("\t\tcase %d: return %d;\n", i, errno);
	}
	printf("\t\tdefault: return EINVAL;\n");
	printf("\t}\n}\n");
}
back to top