An ever-growing collection of bizzare/cursed projects I've created to demonstrate the sheer power of dunder methods. From lists who never raise IndexErrors by wrapping the index, to functions whose invocation is performed with sqaure brackets.
I try to document the files as clearly as possible. Enjoy!
wrappedlist.py - demonstrating __getitem__, __setitem__, __delitem__, and arithmetic dunders.
squarefunction.py - demonstrating __getitem__, __call__, and __get__.
easysubsuper.py - demonstrating rich comparison dunders in a metaclass.