From fbd6510d58a47ea0d166c48a82793f05425406e4 Mon Sep 17 00:00:00 2001 From: Charles Harris Date: Sun, 18 Aug 2013 11:51:25 -0600 Subject: STY: Giant comma spacing fixup. Run the 2to3 ws_comma fixer on *.py files. Some lines are now too long and will need to be broken at some point. OTOH, some lines were already too long and need to be broken at some point. Now seems as good a time as any to do this with open PRs at a minimum. --- numpy/f2py/doc/collectinput.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'numpy/f2py/doc/collectinput.py') diff --git a/numpy/f2py/doc/collectinput.py b/numpy/f2py/doc/collectinput.py index 317fde5b2..2585dae49 100755 --- a/numpy/f2py/doc/collectinput.py +++ b/numpy/f2py/doc/collectinput.py @@ -40,7 +40,7 @@ except: try: fi=sys.argv[1] except: fi=() if not stdoutflag: - sys.stdout=open(fn,'w') + sys.stdout=open(fn, 'w') nonverb=r'[\w\s\\&=\^\*\.\{\(\)\[\?\+\$/]*(?!\\verb.)' input=re.compile(nonverb+r'\\(input|include)\*?\s*\{?.*}?') @@ -59,12 +59,12 @@ for l in fileinput.input(fi): if l[-1]=='}': l=l[:-1] i=m.end()-2 sys.stderr.write('>>>>>>') - while i>-1 and (l[i] not in [' ','{']): i=i-1 + while i>-1 and (l[i] not in [' ', '{']): i=i-1 if i>-1: fn=l[i+1:] - try: f=open(fn,'r'); flag=1; f.close() + try: f=open(fn, 'r'); flag=1; f.close() except: - try: f=open(fn+'.tex','r'); flag=1;fn=fn+'.tex'; f.close() + try: f=open(fn+'.tex', 'r'); flag=1;fn=fn+'.tex'; f.close() except: flag=0 if flag==0: sys.stderr.write('Could not open a file: '+fn+'\n') -- cgit v1.2.1