Skip to content

Commit

Permalink
Merge pull request numpy#15706 from melissawm/f2py-typos-fix
Browse files Browse the repository at this point in the history
MAINT: Fixing typos in f2py comments and code.
  • Loading branch information
charris authored Mar 9, 2020
2 parents 2419293 + 738d985 commit 105e175
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion numpy/f2py/capi_maps.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
from .crackfortran import markoutercomma
from . import cb_rules

# The eviroment provided by auxfuncs.py is needed for some calls to eval.
# The environment provided by auxfuncs.py is needed for some calls to eval.
# As the needed functions cannot be determined by static inspection of the
# code, it is safest to use import * pending a major refactoring of f2py.
from .auxfuncs import *
Expand Down
12 changes: 6 additions & 6 deletions numpy/f2py/crackfortran.py
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@

from . import __version__

# The eviroment provided by auxfuncs.py is needed for some calls to eval.
# The environment provided by auxfuncs.py is needed for some calls to eval.
# As the needed functions cannot be determined by static inspection of the
# code, it is safest to use import * pending a major refactoring of f2py.
from .auxfuncs import *
Expand Down Expand Up @@ -579,8 +579,8 @@ def readfortrancode(ffile, dowithline=show, istop=1):
beforethisafter % ('', 'public', 'public', '.*'), re.I), 'public'
privatepattern = re.compile(
beforethisafter % ('', 'private', 'private', '.*'), re.I), 'private'
intrisicpattern = re.compile(
beforethisafter % ('', 'intrisic', 'intrisic', '.*'), re.I), 'intrisic'
intrinsicpattern = re.compile(
beforethisafter % ('', 'intrinsic', 'intrinsic', '.*'), re.I), 'intrinsic'
intentpattern = re.compile(beforethisafter % (
'', 'intent|depend|note|check', 'intent|depend|note|check', r'\s*\(.*?\).*'), re.I), 'intent'
parameterpattern = re.compile(
Expand Down Expand Up @@ -705,7 +705,7 @@ def crackline(line, reset=0):
for pat in [dimensionpattern, externalpattern, intentpattern, optionalpattern,
requiredpattern,
parameterpattern, datapattern, publicpattern, privatepattern,
intrisicpattern,
intrinsicpattern,
endifpattern, endpattern,
formatpattern,
beginpattern, functionpattern, subroutinepattern,
Expand Down Expand Up @@ -1097,7 +1097,7 @@ def analyzeline(m, case, line):
last_name = updatevars(typespec, selector, attr, edecl)
if last_name is not None:
previous_context = ('variable', last_name, groupcounter)
elif case in ['dimension', 'intent', 'optional', 'required', 'external', 'public', 'private', 'intrisic']:
elif case in ['dimension', 'intent', 'optional', 'required', 'external', 'public', 'private', 'intrinsic']:
edecl = groupcache[groupcounter]['vars']
ll = m.group('after').strip()
i = ll.find('::')
Expand Down Expand Up @@ -1157,7 +1157,7 @@ def analyzeline(m, case, line):
else:
errmess('analyzeline: intent(callback) %s is already'
' in argument list' % (k))
if case in ['optional', 'required', 'public', 'external', 'private', 'intrisic']:
if case in ['optional', 'required', 'public', 'external', 'private', 'intrinsic']:
ap = case
if 'attrspec' in edecl[k]:
edecl[k]['attrspec'].append(ap)
Expand Down
2 changes: 1 addition & 1 deletion numpy/f2py/f90mod_rules.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
from . import func2subr
from .crackfortran import undo_rmbadname, undo_rmbadname1

# The eviroment provided by auxfuncs.py is needed for some calls to eval.
# The environment provided by auxfuncs.py is needed for some calls to eval.
# As the needed functions cannot be determined by static inspection of the
# code, it is safest to use import * pending a major refactoring of f2py.
from .auxfuncs import *
Expand Down

0 comments on commit 105e175

Please sign in to comment.