我想在python中动态创建一个具有特定元类的类的新实例.
我试过这个:
type('A', (object, metaclass=tmp, ), {})
但不起作用:(
有谁知道我怎么能做到这一点?
python metaclass
metaclass ×1
python ×1