8000 BUG: Hotfix for handling common blocks in f2py · numpy/numpy@b8af21f · GitHub
[go: up one dir, main page]

Skip to content

Commit b8af21f

Browse files
committed
BUG: Hotfix for handling common blocks in f2py
1 parent 828fba2 commit b8af21f

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

numpy/f2py/crackfortran.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -614,7 +614,8 @@ def readfortrancode(ffile, dowithline=show, istop=1):
614614
r'endinterface|endsubroutine|endfunction')
615615
endpattern = re.compile(
616616
beforethisafter % ('', groupends, groupends, '.*'), re.I), 'end'
617-
endifs = r'end\s*(if|do|where|select|while|forall|associate|block|' + \
617+
# block, the Fortran 2008 construct needs special handling in the rest of the file
618+
endifs = r'end\s*(if|do|where|select|while|forall|associate|' + \
618619
r'critical|enum|team)'
619620
endifpattern = re.compile(
620621
beforethisafter % (r'[\w]*?', endifs, endifs, '.*'), re.I), 'endif'

0 commit comments

Comments
 (0)
0