[Python-checkins] CVS: python/dist/src/Modules stropmodule.c,2.66,2.67

Peter Schneider-Kamp python-dev@python.org
2000年7月10日 02:43:27 -0700


Update of /cvsroot/python/python/dist/src/Modules
In directory slayer.i.sourceforge.net:/tmp/cvs-serv4667
Modified Files:
	stropmodule.c 
Log Message:
ANSI-fication
Index: stropmodule.c
===================================================================
RCS file: /cvsroot/python/python/dist/src/Modules/stropmodule.c,v
retrieving revision 2.66
retrieving revision 2.67
diff -C2 -r2.66 -r2.67
*** stropmodule.c	2000年07月09日 03:09:55	2.66
--- stropmodule.c	2000年07月10日 09:43:24	2.67
***************
*** 39,46 ****
 
 static PyObject *
! split_whitespace(s, len, maxsplit)
! 	char *s;
! 	int len;
! 	int maxsplit;
 {
 	int i = 0, j, err;
--- 39,43 ----
 
 static PyObject *
! split_whitespace(char *s, int len, int maxsplit)
 {
 	int i = 0, j, err;
***************
*** 108,114 ****
 
 static PyObject *
! strop_splitfields(self, args)
! 	PyObject *self; /* Not used */
! 	PyObject *args;
 {
 	int len, n, i, j, err;
--- 105,109 ----
 
 static PyObject *
! strop_splitfields(PyObject *self, PyObject *args)
 {
 	int len, n, i, j, err;
***************
*** 179,185 ****
 
 static PyObject *
! strop_joinfields(self, args)
! 	PyObject *self; /* Not used */
! 	PyObject *args;
 {
 	PyObject *seq;
--- 174,178 ----
 
 static PyObject *
! strop_joinfields(PyObject *self, PyObject *args)
 {
 	PyObject *seq;
***************
*** 311,317 ****
 
 static PyObject *
! strop_find(self, args)
! 	PyObject *self; /* Not used */
! 	PyObject *args;
 {
 	char *s, *sub;
--- 304,308 ----
 
 static PyObject *
! strop_find(PyObject *self, PyObject *args)
 {
 	char *s, *sub;
***************
*** 355,361 ****
 
 static PyObject *
! strop_rfind(self, args)
! 	PyObject *self; /* Not used */
! 	PyObject *args;
 {
 	char *s, *sub;
--- 346,350 ----
 
 static PyObject *
! strop_rfind(PyObject *self, PyObject *args)
 {
 	char *s, *sub;
***************
*** 390,396 ****
 
 static PyObject *
! do_strip(args, striptype)
! 	PyObject *args;
! 	int striptype;
 {
 	char *s;
--- 379,383 ----
 
 static PyObject *
! do_strip(PyObject *args, int striptype)
 {
 	char *s;
***************
*** 432,438 ****
 
 static PyObject *
! strop_strip(self, args)
! 	PyObject *self; /* Not used */
! 	PyObject *args;
 {
 	return do_strip(args, BOTHSTRIP);
--- 419,423 ----
 
 static PyObject *
! strop_strip(PyObject *self, PyObject *args)
 {
 	return do_strip(args, BOTHSTRIP);
***************
*** 446,452 ****
 
 static PyObject *
! strop_lstrip(self, args)
! 	PyObject *self; /* Not used */
! 	PyObject *args;
 {
 	return do_strip(args, LEFTSTRIP);
--- 431,435 ----
 
 static PyObject *
! strop_lstrip(PyObject *self, PyObject *args)
 {
 	return do_strip(args, LEFTSTRIP);
***************
*** 460,466 ****
 
 static PyObject *
! strop_rstrip(self, args)
! 	PyObject *self; /* Not used */
! 	PyObject *args;
 {
 	return do_strip(args, RIGHTSTRIP);
--- 443,447 ----
 
 static PyObject *
! strop_rstrip(PyObject *self, PyObject *args)
 {
 	return do_strip(args, RIGHTSTRIP);
***************
*** 474,480 ****
 
 static PyObject *
! strop_lower(self, args)
! 	PyObject *self; /* Not used */
! 	PyObject *args;
 {
 	char *s, *s_new;
--- 455,459 ----
 
 static PyObject *
! strop_lower(PyObject *self, PyObject *args)
 {
 	char *s, *s_new;
***************
*** 514,520 ****
 
 static PyObject *
! strop_upper(self, args)
! 	PyObject *self; /* Not used */
! 	PyObject *args;
 {
 	char *s, *s_new;
--- 493,497 ----
 
 static PyObject *
! strop_upper(PyObject *self, PyObject *args)
 {
 	char *s, *s_new;
***************
*** 555,561 ****
 
 static PyObject *
! strop_capitalize(self, args)
! 	PyObject *self; /* Not used */
! 	PyObject *args;
 {
 	char *s, *s_new;
--- 532,536 ----
 
 static PyObject *
! strop_capitalize(PyObject *self, PyObject *args)
 {
 	char *s, *s_new;
***************
*** 607,613 ****
 
 static PyObject *
! strop_expandtabs(self, args)
! 	PyObject *self;
! 	PyObject *args;
 {
 	/* Original by Fredrik Lundh */
--- 582,586 ----
 
 static PyObject *
! strop_expandtabs(PyObject *self, PyObject *args)
 {
 	/* Original by Fredrik Lundh */
***************
*** 679,685 ****
 
 static PyObject *
! strop_count(self, args)
! 	PyObject *self;	/* Not used */
! 	PyObject *args;
 {
 	char *s, *sub;
--- 652,656 ----
 
 static PyObject *
! strop_count(PyObject *self, PyObject *args)
 {
 	char *s, *sub;
***************
*** 724,730 ****
 
 static PyObject *
! strop_swapcase(self, args)
! 	PyObject *self; /* Not used */
! 	PyObject *args;
 {
 	char *s, *s_new;
--- 695,699 ----
 
 static PyObject *
! strop_swapcase(PyObject *self, PyObject *args)
 {
 	char *s, *s_new;
***************
*** 774,780 ****
 
 static PyObject *
! strop_atoi(self, args)
! 	PyObject *self; /* Not used */
! 	PyObject *args;
 {
 	char *s, *end;
--- 743,747 ----
 
 static PyObject *
! strop_atoi(PyObject *self, PyObject *args)
 {
 	char *s, *end;
***************
*** 829,835 ****
 
 static PyObject *
! strop_atol(self, args)
! 	PyObject *self; /* Not used */
! 	PyObject *args;
 {
 	char *s, *end;
--- 796,800 ----
 
 static PyObject *
! strop_atol(PyObject *self, PyObject *args)
 {
 	char *s, *end;
***************
*** 875,881 ****
 
 static PyObject *
! strop_atof(self, args)
! 	PyObject *self; /* Not used */
! 	PyObject *args;
 {
 	extern double strtod(const char *, char **);
--- 840,844 ----
 
 static PyObject *
! strop_atof(PyObject *self, PyObject *args)
 {
 	extern double strtod(const char *, char **);
***************
*** 920,926 ****
 
 static PyObject *
! strop_maketrans(self, args)
! 	PyObject *self; /* Not used */
! 	PyObject *args;
 {
 	unsigned char *c, *from=NULL, *to=NULL;
--- 883,887 ----
 
 static PyObject *
! strop_maketrans(PyObject *self, PyObject *args)
 {
 	unsigned char *c, *from=NULL, *to=NULL;
***************
*** 959,965 ****
 
 static PyObject *
! strop_translate(self, args)
! 	PyObject *self;
! 	PyObject *args;
 {
 	register char *input, *table, *output;
--- 920,924 ----
 
 static PyObject *
! strop_translate(PyObject *self, PyObject *args)
 {
 	register char *input, *table, *output;
***************
*** 1039,1047 ****
 MEM, the function returns -1.
 */
! static int mymemfind(mem, len, pat, pat_len)
! 	char *mem;
! 	int len;
! 	char *pat;
! 	int pat_len;
 {
 	register int ii;
--- 998,1002 ----
 MEM, the function returns -1.
 */
! static int mymemfind(char *mem, int len, char *pat, int pat_len)
 {
 	register int ii;
***************
*** 1067,1075 ****
 mem=11111 and pat==11 also return 2.
 */
! static int mymemcnt(mem, len, pat, pat_len)
! 	char *mem;
! 	int len;
! 	char *pat;
! 	int pat_len;
 {
 	register int offset = 0;
--- 1022,1026 ----
 mem=11111 and pat==11 also return 2.
 */
! static int mymemcnt(char *mem, int len, char *pat, int pat_len)
 {
 	register int offset = 0;
***************
*** 1106,1119 ****
 NULL if an error occurred.
 */
! static char *mymemreplace(str, len, pat, pat_len, sub, sub_len, count, out_len)
! 	char *str;
! 	int len; /* input string */
! 	char *pat;
! 	int pat_len; /* pattern string to find */
! 	char *sub;
! 	int sub_len; /* substitution string */
! 	int count; /* number of replacements, 0 == all */
! 	int *out_len;
! 
 {
 	char *out_s;
--- 1057,1061 ----
 NULL if an error occurred.
 */
! static char *mymemreplace(char *str, int len, char *pat, int pat_len, char *sub, int sub_len, int count, int *out_len)
 {
 	char *out_s;
***************
*** 1176,1182 ****
 
 static PyObject *
! strop_replace(self, args)
! 	PyObject *self;	/* Not used */
! 	PyObject *args;
 {
 	char *str, *pat,*sub,*new_s;
--- 1118,1122 ----
 
 static PyObject *
! strop_replace(PyObject *self, PyObject *args)
 {
 	char *str, *pat,*sub,*new_s;

AltStyle によって変換されたページ (->オリジナル) /