Type: Stage:
Components: Library (Lib) Versions: Python 3.11
Status: open Resolution:
Dependencies: Superseder:
Assigned To: Nosy List: Antony.Lee, hrik2001
Priority: normal Keywords:

Created on 2021-05-03 14:24 by Antony.Lee, last changed 2021-05-04 18:02 by hrik2001.

Messages (1)
msg392809 - (view) Author: Antony Lee (Antony.Lee) * Date: 2021-05-03 14:24
Adding a call/__call__ function to the operator module (where `*args, **kwargs)(func) == func(*args, **kwargs)`, similarly to operator.methodcaller) seems consistent with the design with the rest of the operator module.

An actual use case I had for such an operator was collecting a bunch of callables in a list and wanting to dispatch them to, i.e. something like `, funcs)` (to get the parallelized version of `[func() for func in funcs]`).
Date User Action Args
2021-05-04 18:02:14hrik2001setnosy: + hrik2001
2021-05-03 14:24:00Antony.Leecreate