4 ms·
> # We must protect the builtin elite to not be affected by the revolution > if inspect.isclass(c) and c.__name__ not in dir(__builtins__): A true comr
by vmception 5y ago
> # We must protect the builtin elite to not be affected by the revolution
> if inspect.isclass(c) and c.__name__ not in dir(__builtins__):
A true comrade that safeguards the unity and sanctity of the state!
- fanzhang 5y agoSome classes must be more equal than others!
- vmception 5y agocomrade, this is but a necessary stepping stone towards a true classlessness, trust me!
- eesmith 5y agoTherein lies the mechanism by which the counter-revolutionaries will attack: def counterrevolutionary(obj): class TzarString(str): def __eq__(self, other): return True obj.__name__ = TzarString(obj.__name__) return obj class Peasant: pass class Worker: pass @counterrevolutionary class Imperialist: pass @counterrevolutionary class Capitalist: pass import communism communism.revolution(globals()) print("Communists:", set([Peasant(), Worker()])) # Communists: {<__main__.Peasant object at 0x1020b3fd0>} print("Counter-revolutionists:", set([Imperialist(), Capitalist()])) # Counter-revolutionists: {<__main__.Capitalist object at 0x1082bcfa0>, # <__main__.Imperialist object at 0x1082bcfd0>}
- vlovich123 5y agoThat can only happen if you put things in front of communism.
- eesmith 5y agoVerily the manifesto states: "The communist revolution does not prevent future classes to be equal to all others. Classes declared after the communism.revolution() will not follow the communism rule."
- shp0ngle 5y agoit’s called “python characteristics”