Subj : Re: Array-like calls... I'm totally confused now :-( To : netscape.public.mozilla.jseng From : "Andreas Podgurski" Date : Sat Feb 07 2004 12:25 pm > >1) Is it correct to use JS_SetProperty for this purpose in the C-API? > Sure. What's the problm, exactly? In JS, *any* property name can be > accessed via either foo.bar or foo['bar'] (' or " doesn't matter). Does > this help? Yep, this helped to find the bug and, very important, clarified the mechanism to me. Afterall the bug resulted in a combination of being overtired and using a hardwired property instead one of the free... Sorry. But one thing still confuses me: In the getter/setter of the class, I'm reciving method calls, too. Great thing, opens very new frontiers on using SpiderMonkey, but how do I still tell the engine, that it was tried to access a property that doesn't exist? Before using this callback it was clear, the property setter/getter was there, methods where defined, but now I would have to go through both lists myself to make shure no not existing property passes through, or am I wrong? The confusion started, because I expected to come the hard coded properties to come through this callback as well, but I've never seen it (What doesn't exactly has to mean it wasn't there). It's hard to debug a part which is run through so repeatedly... Second, is there anywhere a documentation or tutorial which describers all callback possibilities of SpiderMonkey? With this I discovered many new possibilities of it and still have the feel, that wasn't all... "Great tool SpiderMonkey is!" Yoda would say ;-) Thanks again, Andreas "SunSailor" Podgurski .