[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [sc-users] Referring to class methods as functions



Method is a subclass of FunctionDef, not of Function, which is partially why you can't use it as a function.

> For instance methods, I understand that you'd need to pass an instance of the object, but for class methods it should be capable of being "free-standing"...no?

This is not quite correct. As a result of the design of SuperCollider's class system, 'class methods' can be viewed as instance methods on a meta-class. So you need to pass an 'instance' (the only instance) of the meta-class.

-Brian