Skip to content

Commit ab0b77d

Browse files
authored
Merge pull request pmodels#6694 from hzhou/2309_f90_ierr
binding/f90: fix ierr as ierror Approved-by: Ken Raffenetti
2 parents 16e1e60 + 66a7300 commit ab0b77d

File tree

2 files changed

+7
-2
lines changed

2 files changed

+7
-2
lines changed

CHANGES

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,11 @@
1111

1212
# Use the error handler bound to MPI_COMM_SELF as the default error handler.
1313

14+
# Use ierror instead of ierr in "use mpi" Fortran interface. This affects
15+
user code if they call with explicit keyword, e.g. call MPI_Init(ierr=arg).
16+
"ierror" is the correct name specified in the MPI specification. We only
17+
added subroutine interface in "mpi.mod" since 4.1.
18+
1419
===============================================================================
1520
Changes in 4.1
1621
===============================================================================

maint/local_python/binding_f90.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -92,8 +92,8 @@ def dump_ignore_tkr():
9292
G.out.append("")
9393
if 'return' not in func:
9494
if not len(f_param_list) or not RE.match(r'ierr(or)?', f_param_list[-1]):
95-
f_param_list.append('ierr')
96-
decl_list.append("INTEGER :: ierr")
95+
f_param_list.append('ierror')
96+
decl_list.append("INTEGER :: ierror")
9797
dump_fortran_line("SUBROUTINE %s(%s)" % (func_name, ', '.join(f_param_list)))
9898
else:
9999
dump_fortran_line("FUNCTION %s(%s) result(res)" % (func_name, ', '.join(f_param_list)))

0 commit comments

Comments
 (0)