pycharm使用metaclass问题
pycharm中输入 __metaclass__=type 会提示 unresolved reference 错误,怎么解决?python新手学习中
__metaclass__ = type
class Rectangle:
def __init__(self):
self.width=0
self.height=0
def __setSize__(self,size):
self.width, self.height=size
def __getSize__(self):
return self.width,self.height
size=property(getSize,setSize)