| 1 | ! audit31 Finding 1: keyword arguments now reorder to match the |
| 2 | ! callee's declared param list (F2003 §12.4.1.2). Previously |
| 3 | ! `call sub(b=10, a=20)` bound positionally → a=10, b=20. A |
| 4 | ! new reorder_args_by_keyword pass runs just before arg lowering |
| 5 | ! at both the Stmt::Call and Expr::FunctionCall sites. Task #482. |
| 6 | ! CHECK: a= 20 b= 10 |
| 7 | program audit31_keyword_args |
| 8 | implicit none |
| 9 | call sub(b=10, a=20) |
| 10 | contains |
| 11 | subroutine sub(a, b) |
| 12 | integer, intent(in) :: a, b |
| 13 | print *, 'a=', a, 'b=', b |
| 14 | end subroutine |
| 15 | end program |
| 16 |