10
Protocols in Python
(til.simonwillison.net)
Welcome to the Python community on the programming.dev Lemmy instance!
Past
November 2023
October 2023
July 2023
August 2023
September 2023
I'm not sure you understand that what a union does or does not do is completely irrelevant and besides the point. Python's protocols add support for structural subtyping, and enable both runtime and build-time type checks without requiring major code changes. Don't you understand what that means?