4 ms·
doing simply funname(args): would work fine
by dependenttypes 6y ago
doing simply
funname(args):
would work fine
- pansa2 6y agoHow would the parser know that’s a function definition and not a function call?
- deleted 6y ago[deleted]
- dependenttypes 6y agoby the :
- pansa2 6y agoThat's too late. The parser needs to know whether it's looking at a definition or a call before that - for example, to know whether to parse "args" as a `parameters` or an `arglist` [0]. [0] https://docs.python.org/3/reference/grammar.html https://docs.python.org/3/reference/grammar.html