3 ms·
> functools.singledispatch works with type annotations[2] Only for the first argument. "Note that the dispatch happens on the type of the first argument, creat
by ebg13 6y ago
> functools.singledispatch works with type annotations[2]
Only for the first argument. "Note that the dispatch happens on the type of the first argument, create your function accordingly".
Making delegated kwargs transparent is 100% cool though and addresses a huge problem with delegated interfaces. I'd use that all the time.
I agree with you about the swiss army thing. I wish it weren't bundled with all this other stuff.
- dragonwriter 6y agoMultimethod library is mature, handles multiple dispatch, works with type annotations, and appears to have been stable and relatively complete more than a half decade before fastcore was released.