7 Jan
2009
7 Jan
'09
10:41 a.m.
Hi, Since CallFrame::callee() returns a JSFunction, callee() always returns 0 for host functions. This means that if you want to know the callee at some later point (e.g. walking up the stack), you'd have to store the callee argument that the host function received, and maintain some mapping from the callFrame to callee. And that only works if you implemented the host function yourself. It would be nice if CallFrame::callee() always gave you the callee, regardless of whether it's a host call or JS call; i.e. change the type of callee() to be InternalFunction. Is there anything that prohibits such a change? (If not, I can try to work out a patch.) Regards, Kent