mirror of
https://github.com/shaka-project/shaka-player.git
synced 2026-06-24 17:35:10 +03:00
685e9d57cf
It is type-safe to alias a class, but not one of its static methods. Aliasing the method without the class makes it a "free call" to invoke the aliased method. A "free call" is when you call a method without the context of its instance of class. There were several cases of this with static methods. This will be enforced by a future release of the compiler, which I believe will lead into compiler support for "this" in static ES6 methods. In ES6, you can use "this" in static methods to refer to the class and call other static methods. Closure compiler doesn't support static "this" yet, but we will start using it as soon as it is supported. Change-Id: I4249db8b6dda9231ebba60ee0d4ad734a692c2fe