On Tue, Jan 21, 2014 at 9:29 AM, Kevin Smith <[email protected]> wrote: > > 2) The current loader is an instance of the Loader type. It is > incongruent to name an instance with a capitalized identifier. I believe it > would be more appropriate to provide access to the current loader via a > getter on the Loader or Realm constructor. For example: > > Realm.loader > Loader.current > etc... >
First, there are plenty of standard bindings on the global object that are not constructors and yet are capitalized -- `Math` is a prime example here. Second, there's no reason that access to a particular loader and access to the Realm or Loader constructors should be related. Third, anything in the `.current` style is introducing inexplicable magic into the platform to have the value of the property vary depending on a property that code otherwise can't observe. Fourth, there can be multiple loaders associated with a given Realm. Fifth, the binding for `System` is not a general mechanism for accessing loaders -- it is a binding for a particular one, the one provided by the host environment. it shouldn't be confused with such a general mechanism (which, as I say above, would be a bad idea anyway). Sam _______________________________________________ es-discuss mailing list [email protected] https://mail.mozilla.org/listinfo/es-discuss

