Hi Steve, thanks for taking this on!
Maybe it would be better to put the checking and argument reordering into its own routine (something like gfc_check_minloc_maxloc in check.c) so all three arguments would be present, with an expression possibly containing NULL, for the later routines. This could add some clarity and save code duplication later, when the second part of the patch is done. However, I do not feel strongly about that. If you feel that your current approach is better, that is fine by me. Regards Thomas