GNOME Bugzilla – Bug 694827
Port the system module to GjsPrivate
Last modified: 2017-01-22 05:41:50 UTC
This is an old patch I had somewhere that bitrotted. I cleaned it up.
Created attachment 237570 [details] [review] Makefile-modules: Clean up
Created attachment 237571 [details] [review] system: Port to GjsPrivate
Review of attachment 237571 [details] [review]: I must say I don't really see the advantage, we still have a native module, and now we have a JS module too. ::: modules/system.js @@ +6,3 @@ + +Lang.copyProperties(imports.systemNative, this); +Lang.copyProperties(imports.gi.GjsPrivate, this); Introspection modules are not enumerable. And in general, this is wrong to do, GjsPrivate includes stuff for format, gettext and overrides/gio.
(In reply to comment #3) > Review of attachment 237571 [details] [review]: > > I must say I don't really see the advantage, we still have a native module, and > now we have a JS module too. I wanted to write an additional system function for debug reasons and got a little annoyed at the boilerplate.
Review of attachment 237570 [details] [review]: Makes sense to me.
Comment on attachment 237570 [details] [review] Makefile-modules: Clean up Attachment 237570 [details] pushed as d378d6d - Makefile-modules: Clean up
With more modern SpiderMonkey the boilerplate has gotten better. I'm going to close this but if you particularly still want to make this change, reopen it and we can discuss.