News for hackers. Stuff that matters.
Re:Implementing Function Overloading in Python by whalesalad on Thursday March 26, 2020 @12:20PM (#22695140)
Singledispatch from functools will often work in a lot of situations where you might want to do something like this: https://docs.python.org/3/library/functools.html

This is a cool post from the author, though. I interpret this as more of an exploration of Python under the hood versus being a recommended production solution.

Python certainly could use a facility to do that based on an arbitrary predicate fn versus type comparison, though.

Python is well suited for this.. maybe it is time to throw a PEP in the ring.

There are no comments on this comment yet.