As an example, instead of hacking the AST via macros:
@case
Point(x, y): pass
one could just do a (this example implies, of course, that there is a CaseClassMeta somewhere attached to CaseClass): class Point(CaseClass):
fields = 'x', 'y'
Not only this is nicer, you retain full control of the MRO on the metaclass level and can adjust its behaviour as needed and when needed.Enums, complex enums and class body nesting examples -- can also be solved via metaclasses quite easily.
Quick lambdas example -- is somewhat close to "whatever" Python library, this is probably the one case which cannot be reproduced as is without AST hacks.