Subj : Re: Binding a global object (again) To : "John J. Lee" From : Brendan Eich Date : Sat Aug 30 2003 05:29 pm John J. Lee wrote: > Brendan Eich writes: > > >>John J. Lee wrote: >> >> >>>I made a second attempt to bind a Python class to the JS global >>>object. This time, my getProperty routine isn't getting called to >>>look up Python attributes on the global object. Previously, I've got >>>by just using getProperty and setProperty. Presumably I need to >>>provide some other functions -- lookupProperty or hasInstance, maybe? >> >>Why are you implementing JSObjectOps? > > > I'm not. None of the JSClass functions appear to be what I (appear > to) need, so I looked at JSPropertyOps. You mentioned lookupProperty, that's only in JSObjectOps. There is no struct named JSPropertyOps, so I'm not sure what you mean here. > I don't understand why my getProperty function isn't getting called in > that case, but my working assumption is that I need to provide some > other similar function to the JS engine. Am I wrong? Hard to say without knowing what cases you mean. Guessing isn't the way to go here. Can you show some code and say how it fails to work the way you expect? /be .