On Thu, Jan 10, 2019 at 6:15 PM Kyle Machulis <kmachu...@mozilla.com> wrote: > In an effort to bring Marie Kondo memes to dev-platform, I'd like to > propose an XPCOM tidying project.
+1. > - Removal of [noscript] methods in interfaces in favor of direct calls via > Cast() where possible. > - Direct getters through Cast() where possible, infallible (also where > possible) otherwise. For avoidance of doubt, since I don't think we have a global Cast() function, this is meant to refer to idioms like: https://searchfox.org/mozilla-central/rev/b4ebbe90ae4d0468fe6232bb4ce90699738c8125/caps/BasePrincipal.h#136-142 and we'd prefer the explicit downcast from an interface pointer (assuming the interface is [builtinclass]) and a C++-side getter, rather than declaring the getter in the interface definition? > This would probably end up continuing making XPCOM interfaces look more > like a guide to shared parts between C++/JS than the template for all > access that is has been for years. +1. -Nathan _______________________________________________ dev-platform mailing list dev-platform@lists.mozilla.org https://lists.mozilla.org/listinfo/dev-platform