[Python-Dev] ANSIfication again ;)

Thomas Wouters thomas@xs4all.net
Thu, 20 Jul 2000 22:13:00 +0200


I just went over all of the Python source, using this little program
(which I called findkrc.py):

import sys, string

for file in sys.argv[1:]
	d = open(file).read()
	if string.find(d, ";\n{") <> -1 or string.find(d, "()\n{") <> -1:
		print file

(using find -name '*.[ch]' -print | xargs ./findkrc.py)

And I fixed almost all of the instances of K&R C syntax. However, I found a
lot of instances of the 2nd type: empty argument list. However, as far as I
remember, ANSI C states that should be written as '(void)'. Is that a
non-issue, and should I not bother fixing those ? (Most of the files in
Modules/ has one or more instances of those.)

I also found a number of files which were already converted to ANSI syntax,
but with one function leftover. Should I bother uploading a patch for those,
or can I just commit them ? They're only a few lines per file, after all.

-- 
Thomas Wouters <thomas@xs4all.net>

Hi! I'm a .signature virus! copy me into your .signature file to help me spread!