Subj : Re: Equivalent of JS_InitClass for global object? To : netscape.public.mozilla.jseng From : jjl@pobox.com (John J. Lee) Date : Tue Aug 26 2003 10:03 pm Brendan Eich writes: > Brendan Eich wrote: > > > David Bradley wrote: [...] > >> Have you looked a PyConnect? The code may be in a bit of disarray, > >> not sure how well maintained it is, but it might be an easier task > >> to get it in order than reinvent it: > >> http://lxr.mozilla.org/mozilla/source/extensions/python/xpcom/ > > > > > > Mark Hammond has updaged it recently. I think it works. Yes, I'm aware of PyXPCOM (if I've got the name right). PyXPCOM is much nicer than my hack, of course, but I didn't want to depend on Mozilla. I also knew I wanted to play around with stuff on top of the DOM and probably hack the DOM occasionally for 'DOM as deployed' compatibility (yuck), for example. I suspected this kind of thing would be easier if all the DOM code was in Python. Also, there were build and interoperability issues with PyXPCOM last time I checked, though looking now I can't tell how far that has been resolved. I wonder if it's part of (or will be part of) the standard Mozilla distribution, in a form that allows standalone scripts to run. [...] > The advantage of PyConnect is that if you go down the JS/Python route, > you're inviting n^2 inter-language-runtime bridge-building. If you > instead choose to build only XPCOM/language bridges, you need n for n > languages. Plus XPCOM, of course. Yeah, but I don't care about those other languages ;-P and XPCOM is just another thing to learn from my PoV (*how* many COM- / CORBA-like component systems on *nix now? 4 or 5, maybe?!). John .