fparser
fparser copied to clipboard
Routine argument list is not a Dummy_Arg_List if it contains a single argument.
Although we recently (#170) moved to allowing lists to contain 1 item, it seems this change hasn't carried through to the handling of routine arguments. When parsing:
subroutine tmp(a, b)
the resulting parse tree is:
Subroutine_Stmt(None, Name('tmp'), Dummy_Arg_List(',', (Name('a'), Name('b'))), None)
but for:
subroutine tmp(a)
it is:
Subroutine_Stmt(None, Name('tmp'), Name('a'), None)