class Foo: pass foo = Foo() print(Foo, type(Foo)) print(foo, type(foo))
类对象与类实例的创建过程(type, metaclass, __new__, __init__, __call__)
原文:https://www.cnblogs.com/zk416605134/p/12655134.html