MozillaZine

SpiderMonkey: how to access callee object in the call-hook?

Discuss building things with or for the Mozilla Platform.
storozhilov
 
Posts: 1
Joined: November 6th, 2009, 3:05 am
November 6th, 2009, 5:21 am

Post Posted November 6th, 2009, 5:21 am

Hi everybody,

using the 'JSClass' structure we can define custom behavior of the ECMAScript value while calling 'JS_NewObject' function. For example, it's possible to interrupt calling ECMAScript value as a function by defining 'call' member in 'JSClass' structure. This 'call' hook has 'JSNative' type for it's signature, that recieves a pointer to 'JSObject' structure that contains 'this'-object handle. So the question is how to access the 'callee'-object handle that represents ECMAScript value, that was actually called as a function?

Thank you much!

Return to Mozilla Development


Who is online

Users browsing this forum: No registered users and 1 guest