I don't think we need to do any special binding to `this` for bare `super`.
Perhaps it will help if I provide the original use case that led me to
this. I'm using AngularJS and declaring controllers as classes. I have a
base FormCtrl that extends (for example) a ClientFormCtrl. The cut-down
version of the constructor is this:

constructor($injector) {
  $injector.invoke(super, this, {
    formName: 'activityUpsertForm'
  });
}

In this case, I don't care what `super` is bound to, since under the covers
Angular is going to do super.apply(this).

I think the most obvious and least confusing/breaking way for `super` to
function is for it to be the equivalent of `let super = super.[method_name]`


On Thu, Aug 7, 2014 at 5:54 AM, Brendan Eich <[email protected]> wrote:

> Rick Waldron wrote:
>
>> I was just curious about what your gut was saying ;)
>>
>
> I was going for alias to `this`. But that argues against `super()` as
> short for `super.method()` in method context. And that means Java, so bleah
> :-P.
>
>
> /be
> _______________________________________________
> es-discuss mailing list
> [email protected]
> https://mail.mozilla.org/listinfo/es-discuss
>
_______________________________________________
es-discuss mailing list
[email protected]
https://mail.mozilla.org/listinfo/es-discuss

Reply via email to