Klaas-Jan Stol wrote:
maybe it'd be useful to allow introspection for that as well? maybe  a sub
can be requested for i ts complete signature, which then returns a some
object describing that signature. (how many params, is it a vararg function, 
how many optionals, etc)
Writing a method to return the signature PMC for a sub wouldn't be hard (take the implementation of arity and delete some code ;-)), though whether it's the easiest thing to work with, on the other hand... (Basically, it's an array of bit fields, but it contains all the information that the calling conventions have available to them.)

Which reminds me, we probably want to be caching arity in the Sub PMC's data structure itself, though I've not gotten around to that yet.

Jonathan

Reply via email to