Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我在视觉作品 smalltalk 中创建了一个类,添加了一个方法(例如:list),但是当我在工作区中调用它时,它显示错误消息,例如消息不理解 #list。
先感谢您。
我确定您将消息发送给班级而不是实例,因此您需要先发送#new。
如果你创建一个像“Foo”这样的类并添加一个像“bar”这样的实例方法,你需要评估:
Foo new bar